Users should not be able to edit content hierarchy
Why?
By editing the parent selection it is possible to create a circular reference loop between two learning objects pointing to each other as a parent, that leads to excessive number of database operations, and as a result, leading the system to become unusable due to heavy database load.
How?
The two fields, parent and course module, have been made readonly and have been disabled. So they cannot be changed.
Fixes #
Testing
What type of test did you run?
[ ] Django unit tests.
[ ] Selenium tests.
[ ] Manual testing.
After making the changes, the parent and course module fields are no longer editable for teachers as shown in the picture above.
Did you test the changes in
[ ] Chrome
[ ] Firefox
[ ] This pull request cannot be tested in the browser.
Think of what is affected by these changes and could become broken
Fixes #1306
Description
What?
Users should not be able to edit content hierarchy
Why?
By editing the parent selection it is possible to create a circular reference loop between two learning objects pointing to each other as a parent, that leads to excessive number of database operations, and as a result, leading the system to become unusable due to heavy database load.
How?
The two fields, parent and course module, have been made readonly and have been disabled. So they cannot be changed.
Fixes #
Testing
What type of test did you run?
After making the changes, the parent and course module fields are no longer editable for teachers as shown in the picture above.
Did you test the changes in
Think of what is affected by these changes and could become broken
Translation
Programming style
Have you updated the README or other relevant documentation?
Is it Done?
Clean up your git commit history before submitting the pull request!