Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Teacher participations are saved in quiz-student relation table #200

Open
Laczse opened this issue Dec 4, 2024 · 0 comments
Open

Teacher participations are saved in quiz-student relation table #200

Laczse opened this issue Dec 4, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@Laczse
Copy link
Contributor

Laczse commented Dec 4, 2024

Teacher participations are saved in quiz-student relation table as there are no other place to store them.
This creates problems for editing and deleting questions, as well as being against the desig of the database.
There is currently a solution implemented for editing and deleting questions, however it is not very elegant.

To fix this issue the following should be done:

  1. Update the database to have a quiz-teacher relation table and a teacher-answer relation table (This should be done in install.xml and upgrade.php)
  2. Create the required methods to insert and retrieve data from/to the new table
  3. Remove the code in view.php that deletes all quiz-student relations by id and all student-answer relations by id
  4. Update the code in submit_quiz.php to differentiate between students and teachers. Saving their participations and answer relations in the correct table
  5. Update code that retrieves participations and answer-student relations to differentiate between teachers and students. (This is partly in results.php and results_page.php, but other places may be relevant)
  6. Manually test to see if you can take a livequiz as a teacher and then edit the questions
  7. Run behat tests to ensure everything still works
@Laczse Laczse added the enhancement New feature or request label Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant