Get all errors along with fields the error is connected to

前端 未结 7 1513
予麋鹿
予麋鹿 2021-01-03 06:43

I\'m using Symfony2 forms to validate POST and PUT requests to an API. The form handles binding the request data to the underlying entity and then validating the entity. Eve

7条回答
  •  夕颜
    夕颜 (楼主)
    2021-01-03 07:08

    You can take getErrorsAsString method as an example to get the functionality you want. Also you have to set invalid_message option on the form field to change This value is invalid message.

提交回复
热议问题