Merge pull request #586 from PedroTroller/fix/subform-options

Pass children options to subform
This commit is contained in:
William Durand 2015-05-16 13:07:10 +02:00
commit 647131ab8e

View File

@ -132,6 +132,7 @@ class FormTypeParser implements ParserInterface
$parameters = array();
foreach ($form as $name => $child) {
$config = $child->getConfig();
$options = $config->getOptions();
$bestType = '';
$actualType = null;
$subType = null;
@ -177,7 +178,7 @@ class FormTypeParser implements ParserInterface
*/
$addDefault = false;
try {
$subForm = $this->formFactory->create($type);
$subForm = $this->formFactory->create($type, null, $options);
$subParameters = $this->parseForm($subForm, $name);
if (!empty($subParameters)) {