Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-50678

Teacher error on opening glossaries with 2+ activity completion in restrict access module

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Create a glossary module on the front page and in a course
      2. Make sure auth user / student can access it
      3. Make the glossary hidden
      4. Make sure auth user / student can not access it (type URL directly and make sure the error is displayed)
      5. Run the behat test that was introduced in MDL-49434 on stable versions and make sure it passes
      Show
      Create a glossary module on the front page and in a course Make sure auth user / student can access it Make the glossary hidden Make sure auth user / student can not access it (type URL directly and make sure the error is displayed) Run the behat test that was introduced in MDL-49434 on stable versions and make sure it passes
    • Affected Branches:
      MOODLE_27_STABLE
    • Fixed Branches:
      MOODLE_28_STABLE, MOODLE_29_STABLE
    • Pull Master Branch:
      wip-MDL-50678-master

      Description

      MDL-49418 reported a similar problem for a restricted access module with 2 or more activity completion requirements. It was fixed for 2.7.7 but not however fixed for glossaries. Teachers (who have not completed the 2+ activities required by the restrict access in a section/topic module) receive this error message when attempting to open a glossary in the restricted section:

      "Coding error detected, it must be fixed by a programmer: The theme has already been set up for this page ready for output. Therefore, you can no longer change the theme, or anything that might affect what the current theme is, for example, the course."

      Students, who can only see the glossary after having completed restrict access conditions, don't have a problem. Triage: If the teacher goes to student view and completes the required activities, glossary can then be opened in teacher's normal view. If the number of activity requirements is changed to 1, then the teacher can also get access.

      How to replicate this problem in Moodle 2.7.8 (Build: 20150511):
      1. login a teacher account
      2. In a course, enable completion tracking
      3. create two activities or resources with completion tracking conditions (ie student can manually mark, or create conditions.)
      4. In a different section, edit the section summary and restrict access with activity completion of the two above activities/resources
      5. Create an glossary in the restricted access section. Save.
      6. Click on the glossary to open.
      7. error appears where one would expect to be able to view the glossary.
      8. go to student view
      9. verify student cannot see the glossary or other items in the restricted section.
      10. complete the two required activities or resources
      11. verity student can now see and open the glossary
      12 return to normal view
      13. click the glossary to open
      14. now glossary opens as expected, no error

      This might affect other versions fixed by MDL-49418. I tested with quizzes, forums, files, books and lessons in the restricted section and they don't have an error when opening, only glossaries.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                marina Marina Glancy
                Reporter:
                nwebb01 Nancy Webb
                Peer reviewer:
                Sam Marshall
                Integrator:
                Dan Poltawski
                Tester:
                Jetha Chan
                Participants:
                Component watchers:
                Sam Marshall, Amaia Anabitarte, Bas Brands, Carlos Escobedo, Sara Arjona (@sarjona), Víctor Déniz Falcón, Sam Marshall, Jake Dallimore, Jun Pataleta, Ryan Wyllie, Adrian Greeve, Mihail Geshoski, Peter Dias
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  14/Sep/15