I need to check information when updating an item, to know if saving is allowed or not. This must be done in the backend after the user have clicked on 'UPDATE' button. I'm using Symfony and the existing methods in CRUDController. Is there any method I can add in Controller or Entity so I can add code that does this check before saving?
Asked
Active
Viewed 33 times
1 Answers
0
You have multiple ways to set validation with Symfony.
If I understand well your question, you maybe need to look at the callbacks
https://symfony.com/doc/current/reference/constraints/Callback.html
The purpose is to create custom validation with dedicated functions (like only saving an item if it meets some requirement.)

Lou
- 26
- 2
- 5