SuiteCRM-Core
SuiteCRM-Core copied to clipboard
Fix/329 submit required
Description
Check Detail View defs to see if any field has it's require for submit (required_f_submit) flag set to 'True', if it does, it will disable the "Submit button" until that field is populated. The User should still be able to use the other buttons like 'Save & Continue' without those fields being populated.
Motivation and Context
If "Submit" button added on a module, this feature will disable the button until related field is populated or validated. In this scenerio, the record view has "Submit", "Save and Continue" and "Cancel" buttons. Instead of "Save" button, we have "Save and Continue" but this doesnt submit the record to database. It actually save the record temporarily and doesnt exist edit view. When all fields are ready to be sent to database, "Submit" button is clicked. But, some fields are necessary to be populated to be able submit the record.
How To Test This
Create a submit button on a module. This button needs to send the data to database after an edit. During editing, without populating required fields (required_f_submit flag in their related detailviewdefs' fields), submit button needs to be kept disabled until all required fields are populated.
Types of changes
- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
Final checklist
- [x] My code follows the code style of this project found here.
- [x] My change requires a change to the documentation.
- [x] I have read the How to Contribute guidelines.