I have form:
My code to Tag1 look like:
$builder
->add('tag1', 'collection', [
'type' => 'text',
'label' => 'Tag1',
'allow_add' => true,
'allow_delete' => true,
'prototype' => true,
'options' =>
[
'required' => false,
'label' => false
]
])
But how add Sub form in field? Thanks!
Hi i think it's quite simple.
$builder
->add('tag1', 'collection', [
'type' => new yourSubFormType(),
...
])
more information : http://symfony.com/doc/current/cookbook/form/form_collections.html