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

Allow guests to view wiki on the frontpage

XMLWordPrintable

    • MOODLE_34_STABLE
    • MOODLE_33_STABLE, MOODLE_34_STABLE
    • wip-MDL-61163-master
    • Hide

      Test 1:

      1. Create a new instance of moodle
      2. As admin/manager create a wiki module on the front page and add at least one page to it
      3. Log out (and make sure you don't log in as guest)
      4. Make sure you are able to view wiki on the front page, click on all available links and make sure everything is displayed (history, files, map, compare revisions, etc).
      5. Log in as an ordinary user
      6. Make sure you are able to view wiki

      Test 2:

      1. Create an instance of wiki module in a course
      2. Make sure student is able to see the link to the wiki on the course page and can click on it and view the actual wiki. Copy the URL to the wiki
      3. As admin prohibit 'mod/wiki:viewpages' in the student role
      4. Login again as a student
      5. Make sure you don't see the link to the wiki on the course page and if you paste URL you saved before you get a permission error.
      Show
      Test 1: Create a new instance of moodle As admin/manager create a wiki module on the front page and add at least one page to it Log out (and make sure you don't log in as guest) Make sure you are able to view wiki on the front page, click on all available links and make sure everything is displayed (history, files, map, compare revisions, etc). Log in as an ordinary user Make sure you are able to view wiki Test 2: Create an instance of wiki module in a course Make sure student is able to see the link to the wiki on the course page and can click on it and view the actual wiki. Copy the URL to the wiki As admin prohibit 'mod/wiki:viewpages' in the student role Login again as a student Make sure you don't see the link to the wiki on the course page and if you paste URL you saved before you get a permission error.

      If wiki is created on the frontpage and capability mod/wiki:viewpage is given to guests, guests are still not able to view wiki without pressing "Log in as a guest".

      This is different from the situation with mod_forum and mod_resource - if relevant view capabilitiy is given to the guests they can view the resources.

      This is just a matter of replacing require_login() with require_course_login()

      During development I noticed two more bugs: 1. Capability to view wiki is allowed for guests but not allowed for authenticated users on a frontpage, meaning that guests are able to see the module but as soon as they login they no longer can see it
      2. When displaying the list of modules link to the wiki is shown even when user does not have capability to view it. When user clicks on it an error is displayed.

        1. Confirmed and Verified Test1.png
          195 kB
          Gladys Basiana
        2. Confirmed and Verified Test2.png
          247 kB
          Gladys Basiana
        3. Test1_ List of Wiki_when logged out.PNG
          24 kB
          Gladys Basiana
        4. Test1_Wasn't able to view wiki_when log in as a student.PNG
          32 kB
          Gladys Basiana
        5. Test1_Wasn't able to view wiki_when log in as a teacher.PNG
          32 kB
          Gladys Basiana

            marina Marina Glancy
            marina Marina Glancy
            Tim Hunt Tim Hunt
            Jake Dallimore Jake Dallimore
            Gladys Basiana Gladys Basiana
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 hours
                3h

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.