I have an entity form field in my Symfony2 project.
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
->add('productId', 'genemu_jquerychosen_entity', array(
'class' => 'EMRSabaBundle:Product',
'property' => 'name'
))
;
}
The Product entity has some objects like price, name, mode, & id
I want to let user choose the product by name & see chosen produc's price, then submit product ID, not name.
Is there any soloution?