Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.5
-
MOODLE_35_STABLE
-
MOODLE_35_STABLE
-
MDL-61364-master -
Hide
Set up
- Log in as admin
- Create 2 courses, c1 and c2
- Enrol a user, t1, as a teacher in both courses
- Enrol a user, t2, as a teacher only in c1
- Create the Question sharer role and assign it to t1 and t2 in the system context
- Note: When defining the permissions for the Question sharer role set the moodle/question:tagall permission to "Allow"
Course question
- Log in as t1
- Navigate to c1 and view the question bank questions
- Edit cog > question bank > questions
- Create a new question (q1) in the “Default for c1” category (doesn’t matter what the question type is)
- In the “Tags” section add the tag “c1 tag”
- Save changes
- In the question bank questions view click the tags icon in line with question q1
- CONFIRM that a single "Tags" section with "c1 tag" in it appears
- CONFIRM that you do not see a "Course: <course name> tags" section
- CONFIRM that you can modify the tags by deleting the existing tags and adding new ones
- Save changes
- Click the tags icon again to open the modal again
- CONFIRM that the changes you made to the tags above are still there
- Log in as t2
- Navigate to c1 and view the question bank questions
- Click the tags icon in line with question q1
- CONFIRM that the tags in the "Tags" section are the same as above
- CONFIRM that you do not see a "Course: <course name> tags" section
- CONFIRM that you can edit the tags as described above
Activity question
- Log in as t1
- Navigate to c1
- Create and view a quiz activity (quiz1)
- View the question bank questions from the quiz activity
- edit cog > question bank > questions
- Set “Select a category” to “Default for quiz1”
- Create a new question (q2) (doesn’t matter what the question type is)
- In the “Tags” section add the tag “a1 tag”
- Save changes
- Set “Select a category” to “Default for quiz1”
- In the question bank questions view click the tags icon in line with question q2
- CONFIRM that a single "Tags" section with "a1 tag" in it appears
- CONFIRM that you do not see a "Course: <course name> tags" section
- CONFIRM that you can modify the tags by deleting the existing tags and adding new ones
- Save changes
- Click the tags icon again to open the modal again
- CONFIRM that the changes you made to the tags above are still there
- Log in as t2
- Navigate to quiz1 and view the question bank questions
- Set “Select a category” to “Default for quiz1”
- Click the tags icon in line with question q2
- CONFIRM that the tags in the "Tags" section are the same as above
- CONFIRM that you do not see a "Course: <course name> tags" section
- CONFIRM that you can edit the tags as described above
Course category question
- Log in as t1
- Navigate to c1 and view the question bank questions
- Set “Select a category” to "Default for Miscellaneous"
- Create a new question (q3) (doesn't matter what the question type is)
- Add a tag "cc1 tag" to the "Tags" section
- Add a tag "c1 tag" to the course tags (something like “Course: Course 1 tags”) section
- Save changes
- Set “Select a category” to “Default for Miscellaneous
- In the question bank questions view click the tags icon in line with question q3
- CONFIRM that a "Tags" section with "cc1 tag" in it appears
- CONFIRM that a "Course: <course name> tags" section appears with "c1 tag" in it
- CONFIRM that you can modify the tags in each of the 2 sections by deleting the existing tags and adding new ones
- Save changes
- Click the tags icon again to open the modal again
- CONFIRM that the changes you made to the tags above are still there
- Log in as t2
- Navigate to c1 and view the question bank questions
- Set “Select a category” to “Default for Miscellaneous”
- Click the tags icon in line with question q3
- CONFIRM that the tags in the "Tags" section are the same as above
- CONFIRM that the tags in the "Course: <course name> tags" section are the same as above
- CONFIRM that you can edit the tags as described above
Course category shared question
- Log in as t1
- Navigate to c2 and view the question bank questions
- Set “Select a category” to the “Default for Miscellaneous"
- Click the tags icon in line with question q3
- CONFIRM that you see a section for "Tags". These tags should be shared by all courses in that category so you should see the tags that you added to this section in the previous test.
- CONFIRM that you see a section for course tags. This time it’s the tags for c2 so it should be empty. You should not see the c1 tags you added to the course tags section in the previous test.
- Add some tags to the c2 course tags section
- Modify (add and/or remove) tags from the "Tags" section
- Save changes
- Click the tags icon in line with question q3
- CONFIRM that the changes you made to the tags above were saved
- Navigate to c1 and view the question bank questions
- Set “Select a category” to the “Default for Miscellaneous"
- Click the tags icon in line with question q3
- CONFIRM that you see the same values in the "Tags" section as you did after modifying them a few steps ago
- CONFIRM that you do not see the c2 course tags that you set a few steps ago, instead you should see a course tags section for c1 and it should have the values that were last set on them in the previous "Course category question" test
ShowSet up Log in as admin Create 2 courses, c1 and c2 Enrol a user, t1, as a teacher in both courses Enrol a user, t2, as a teacher only in c1 Create the Question sharer role and assign it to t1 and t2 in the system context Note: When defining the permissions for the Question sharer role set the moodle/question:tagall permission to "Allow" Course question Log in as t1 Navigate to c1 and view the question bank questions Edit cog > question bank > questions Create a new question (q1) in the “Default for c1” category (doesn’t matter what the question type is) In the “Tags” section add the tag “c1 tag” Save changes In the question bank questions view click the tags icon in line with question q1 CONFIRM that a single "Tags" section with "c1 tag" in it appears CONFIRM that you do not see a "Course: <course name> tags" section CONFIRM that you can modify the tags by deleting the existing tags and adding new ones Save changes Click the tags icon again to open the modal again CONFIRM that the changes you made to the tags above are still there Log in as t2 Navigate to c1 and view the question bank questions Click the tags icon in line with question q1 CONFIRM that the tags in the "Tags" section are the same as above CONFIRM that you do not see a "Course: <course name> tags" section CONFIRM that you can edit the tags as described above Activity question Log in as t1 Navigate to c1 Create and view a quiz activity (quiz1) View the question bank questions from the quiz activity edit cog > question bank > questions Set “Select a category” to “Default for quiz1” Create a new question (q2) (doesn’t matter what the question type is) In the “Tags” section add the tag “a1 tag” Save changes Set “Select a category” to “Default for quiz1” In the question bank questions view click the tags icon in line with question q2 CONFIRM that a single "Tags" section with "a1 tag" in it appears CONFIRM that you do not see a "Course: <course name> tags" section CONFIRM that you can modify the tags by deleting the existing tags and adding new ones Save changes Click the tags icon again to open the modal again CONFIRM that the changes you made to the tags above are still there Log in as t2 Navigate to quiz1 and view the question bank questions Set “Select a category” to “Default for quiz1” Click the tags icon in line with question q2 CONFIRM that the tags in the "Tags" section are the same as above CONFIRM that you do not see a "Course: <course name> tags" section CONFIRM that you can edit the tags as described above Course category question Log in as t1 Navigate to c1 and view the question bank questions Set “Select a category” to "Default for Miscellaneous" Create a new question (q3) (doesn't matter what the question type is) Add a tag "cc1 tag" to the "Tags" section Add a tag "c1 tag" to the course tags (something like “Course: Course 1 tags”) section Save changes Set “Select a category” to “Default for Miscellaneous In the question bank questions view click the tags icon in line with question q3 CONFIRM that a "Tags" section with "cc1 tag" in it appears CONFIRM that a "Course: <course name> tags" section appears with "c1 tag" in it CONFIRM that you can modify the tags in each of the 2 sections by deleting the existing tags and adding new ones Save changes Click the tags icon again to open the modal again CONFIRM that the changes you made to the tags above are still there Log in as t2 Navigate to c1 and view the question bank questions Set “Select a category” to “Default for Miscellaneous” Click the tags icon in line with question q3 CONFIRM that the tags in the "Tags" section are the same as above CONFIRM that the tags in the "Course: <course name> tags" section are the same as above CONFIRM that you can edit the tags as described above Course category shared question Log in as t1 Navigate to c2 and view the question bank questions Set “Select a category” to the “Default for Miscellaneous" Click the tags icon in line with question q3 CONFIRM that you see a section for "Tags". These tags should be shared by all courses in that category so you should see the tags that you added to this section in the previous test. CONFIRM that you see a section for course tags. This time it’s the tags for c2 so it should be empty. You should not see the c1 tags you added to the course tags section in the previous test. Add some tags to the c2 course tags section Modify (add and/or remove) tags from the "Tags" section Save changes Click the tags icon in line with question q3 CONFIRM that the changes you made to the tags above were saved Navigate to c1 and view the question bank questions Set “Select a category” to the “Default for Miscellaneous" Click the tags icon in line with question q3 CONFIRM that you see the same values in the "Tags" section as you did after modifying them a few steps ago CONFIRM that you do not see the c2 course tags that you set a few steps ago, instead you should see a course tags section for c1 and it should have the values that were last set on them in the previous "Course category question" test
Attachments
Issue Links
- Discovered while testing
-
MDL-61773 Deprecate question_has_capability_on and split it in two new functions
-
- Open
-
- is blocked by
-
MDL-61133 Create new modal for tag add/edit/remove
-
- Closed
-
-
MDL-61363 Add a section to the edit questions mform to allow managing the course context question tags
-
- Closed
-
- will help resolve
-
MDL-61084 As a teacher, I can add tag(s) to a question bank question for use in my course for organizational and search/filtering of questions.
-
- Closed
-