apluslms / a-plus

A+ frontend portal - A+ LMS documentation:
https://apluslms.github.io/
Other
65 stars 72 forks source link

Users should not be able to edit content hierarchy #1308

Closed khattam2 closed 8 months ago

khattam2 commented 9 months ago

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

image

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!