I want to edit 2 columns in a table through 1 dropdown. The dropdown will contain a Menu with its children MenuNodes.
It would be preferable if I could add the choices as Entities but I am not sure if this can be achieved. Otherwise adding the items as "M1" (Menu with Id of 1) and "N1" (MenuNode with Id of 1). I am not sure if I need to use a FormEvent, Datatransformer or both to achieve this. From what I understand a DataTransformer will only transforms the dropdown value so I am not able to access any of the other columns? My menu entity looks like this: Id menuId parentId name I have tried creating a field in my form which has a property_path of false and then tried modifying the data using the PRE_SET_DATA, BIND FormEvents etc but I cannot achieve this. If the user chooses a MenuNode I need to set the menuId to MenuNode->getMenu()->getId() as the menuNode will belong to a menu and set the parent to whatever node was chosen. If the user chooses just a menuId I need to set that menuId and then set the parentId to NULL. Has anyone had any success with something like this? -- -- If you want to report a vulnerability issue on Symfony, please read the procedure on http://symfony.com/security You received this message because you are subscribed to the Google Groups "symfony developers" group. To post to this group, send email to symfony-devs@googlegroups.com To unsubscribe from this group, send email to symfony-devs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-devs?hl=en --- You received this message because you are subscribed to the Google Groups "Symfony developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to symfony-devs+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.