This commit adds validation for course advanced settings. Currently when course
administrators make invalid changes in the Settings/Advanced Settings tab,
they're not notified through a new modal window of the list of invalid settings
changes.
* Extending CourseMetadata
- Previously, we only had update_from_json method in CourseMetadata.py,
and it was only validating one field every POST request.
- Now we have validate_and_update_from_json method that encapsulates the
functionality of update_from_json into a validation call
- To avoid discrepancy of validation standards between modules, validation
uses the from_json method implemented to each field in xblock.
* Different Response in advanced settings ajax requests
- After receiving a POST ajax request, course.py calls
validate_and_update_from_json, and sends a json object of either:
1) valid course metadata model
2) error objects
* Error Messages shown in validation-error-modal
- error objects passed through ajax are shown in a separate modal.
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| _account.scss | Loading commit data... | |
| _assets.scss | Loading commit data... | |
| _checklists.scss | Loading commit data... | |
| _container.scss | Loading commit data... | |
| _course-create.scss | Loading commit data... | |
| _dashboard.scss | Loading commit data... | |
| _export-git.scss | Loading commit data... | |
| _export.scss | Loading commit data... | |
| _group-configuration.scss | Loading commit data... | |
| _import.scss | Loading commit data... | |
| _index.scss | Loading commit data... | |
| _outline.scss | Loading commit data... | |
| _settings.scss | Loading commit data... | |
| _static-pages.scss | Loading commit data... | |
| _textbooks.scss | Loading commit data... | |
| _unit.scss | Loading commit data... | |
| _updates.scss | Loading commit data... | |
| _users.scss | Loading commit data... |