[form controller] clear caches in case some attribute participating to the rest path has been modified, avoid redirection to a no more existant page (fix #753567)
[form] fix validation error handling
* type when possible ValidationError raised by the edit controller
* don't rely on repository to check required field
* turn css class used for field error message to errorMsg to avoid
confusion with the error class added to input
* fix css when errors are added by the form renderer
* fix form renderer to add the error message