[Form] Allow setting different options to repeating fields
This commit is contained in:
parent
18d3dfe0bf
commit
8819db3923
@ -27,8 +27,9 @@ class RepeatedType extends AbstractType
|
||||
$options['first_name'],
|
||||
$options['second_name'],
|
||||
)))
|
||||
->add($options['first_name'], $options['type'], $options['options'])
|
||||
->add($options['second_name'], $options['type'], $options['options'])
|
||||
->add($options['first_name'], $options['type'], 0 < count($options['first_options']) ? $options['first_options'] : $options['options'])
|
||||
->add($options['second_name'], $options['type'], 0 < count($options['second_options']) ? $options['second_options'] : $options['options'])
|
||||
|
||||
;
|
||||
}
|
||||
|
||||
@ -40,6 +41,8 @@ class RepeatedType extends AbstractType
|
||||
return array(
|
||||
'type' => 'text',
|
||||
'options' => array(),
|
||||
'first_options' => array(),
|
||||
'second_options' => array(),
|
||||
'first_name' => 'first',
|
||||
'second_name' => 'second',
|
||||
'error_bubbling' => false,
|
||||
|
Reference in New Issue
Block a user