studentquiz / moodle-mod_studentquiz

Moodle-Plugin
GNU General Public License v3.0
38 stars 37 forks source link

Backup and Restore with tags fails #419

Closed RahelPhasen closed 1 year ago

RahelPhasen commented 1 year ago

Hi, we found an error when using tags in combination with the studentquiz plugin. Steps to reproduce: 1) Create an activity with one question 2) Assign a few tags to this question in the edit/add form 3) Do a backup and restore of this activity in this course 4) Have a look into this duplicated course; You'll see the assigned tags in the overview table but as soon as you try to edit the question because you'd like to delete one of the existing tags, they aren't there anymore.

Here's how it looks like:

image image (The second picture shows the edit form of the second question calles "Wetter")

So the tags aren't listed in the edit mode. I not sure if I found the mistake in the code. I feel like there is an Issue when doing the backup. I think the tags aren't getting assinged the right context.

timhunt commented 1 year ago

Can I just check, which version of StudentQuiz are you using, with which version of Moodle? Thanks.

RahelPhasen commented 1 year ago

We are using Moodle 3.11.8 and or StudentQuiz version is v4.5.0.

oucnelson commented 1 year ago

Confirmed. Using the latest version of StudentQuiz on our Moodle 4.0 server, I can confirm that the tag is 'lost' on the Edit question form within StudentQuiz, despite being visible in the StudentQuiz table and in the question bank for the restored activity. We will try to fix this defect as soon as we can.

timhunt commented 1 year ago

This was caused by MDL-76193, which has now been fixed in supported Moodel versions. Nothing needs to be changed in StudentQuiz, so I am closing this now.