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

Lesson should have a capability mod/lesson:view

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9, 3.1.1
    • Fix Version/s: 3.2
    • Component/s: Lesson
    • Labels:
    • Testing Instructions:
      Hide

      Manual testing:
      This requires a course with at least 2 student users.

      1. Create a lesson activity with 1 content page and a linked media file
      2. Override the permissions on the lesson activity so the lesson:view permission is prohibited for student2
      3. Have student1 view the lesson page
      4. Have student1 view the media file (make note of the URL as you will need this later)
      5. Verify the lesson activity does not appear to student 2
      6. Have student2 try to directly access the media file (by using the URL you noted earlier). Verify that they do not have access.

      Automated testing:

      1. Run behat for mod_lesson
      2. Run phpunit for mod_lesson
      Show
      Manual testing: This requires a course with at least 2 student users. Create a lesson activity with 1 content page and a linked media file Override the permissions on the lesson activity so the lesson:view permission is prohibited for student2 Have student1 view the lesson page Have student1 view the media file (make note of the URL as you will need this later) Verify the lesson activity does not appear to student 2 Have student2 try to directly access the media file (by using the URL you noted earlier). Verify that they do not have access. Automated testing: Run behat for mod_lesson Run phpunit for mod_lesson
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_19_STABLE, MOODLE_31_STABLE
    • Fixed Branches:
      MOODLE_32_STABLE
    • Pull Master Branch:
      MDL-14448_m32v1

      Description

      Lesson currently has only two capabilities: edit and manage. For consistency with other activities, it should also have mod/lesson:view. Without a view capability, Lessons cannot be hidden from guests in courses that permit guest access (see http://moodle.org/mod/forum/discuss.php?d=95325)

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  6 Vote for this issue
                  Watchers:
                  5 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    5/Dec/16