Symfony 3 DTOOneCommand changing null value to 0 after handleRequest

I am working on a Symfony 3 project and I am facing a problem. When my form is submitted it changed the value from null to zero. But I would like that it keeps value it is sent. Because for me null is different than 0.

I have dump like (form use create form from scenarioProposalVersionModelizeCommand):


Output so this 3 last values as you can see are transformed:

enter image description here

Source: Symfony Questions

Was this helpful?

0 / 0

Leave a Reply 0

Your email address will not be published. Required fields are marked *