Answer the question
In order to leave comments, you need to log in
How to make fields for formbuilder taken from each symfony2 entity?
Again, the question is all about the same symfony2)
Entity can be used in the formbuilder as a choice, but then a select and one data input field are rendered, but how can I make a separate input render for each entry from the database? I think it will be easier to understand with pictures.
This is how it should be,
Phone 1, phone 2 are taken from the database:
...
$builder
->add('phone', 'entity', array(
'class' => 'Acme\DemoBundle\Entity\Phone',
'property' => 'name'
))
->add('note')
->add('button', 'submit');
...
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question