vendredi 27 février 2015

Symfony2: validation of form collection

I have a collection of element within a form. I want to apply validation rules on these elements, but the rules have to be different for the elements updated and the newly created element.


Ex: a collection of 4 elements. Adding the 5th element, a check has to be done on this element only. Updating the 3th element, another check has to be done, on this element only. Deleting the 1st element, a 3th check shall be done.


How is it possible ? (note: I use Propel)


Aucun commentaire:

Enregistrer un commentaire