Constraints on currencies instead of required fields
We have this [Do Not Test Required In Field View Form](https://www.erp5.com/documentation/developer/guideline/module/erp5-Guideline.Module.Creation#do-not-test-required-in-field-view-form rule) rule: > This kind of constraint should be defined in Constraints documents and should to be checked in workflow transitions. > > Checking a field as "required" can cause problems like not saving the data when the user clicks on the save button. The same applies to the use of External Validators scripts in fields. Currency view was not respecting this, there was both required fields and external validator. Also, the external validator was using an incorrect way of getting the "context document", so it was not working on RenderJS UI. We are removing required fields and validator here, because this should be implemented using constraints instead. To somehow preserve the same behavior, a new constraint is added in `erp5_base` and enabled in `erp5_configurator_standard`. Custom projects probably want to enable this constraint, but (as far as I know) we don't enable constraint by default. This `Base_uniqueReferenceInFolderValidator` was apparently not used anywhere else and not working anymore, so we are just removing it. /reviewed-on !710
Showing
Please register or sign in to comment