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

Evaluate the best way to deal with permissions in a delegated section

XMLWordPrintable

    • MOODLE_405_STABLE
    • MDL-81674-main
    • Hide

      Create a course C1:

      • Create a subsection S1 with an assignment activity A1
      • Create an assignment activity A2 in a section S2 (not subsection)
      • Create a subsection S3 with an assignment activity A3
      • Create an assignment activity A4 in a section S4 (not subsection)
      • Enroll a Student student1
      • Hide S1
      • Hide S2
      • Set restriction for S3 so it is visible on the day after today
      • Set restriction for S4 so it is visible on the day after today
      • Copy the direct URL for S1, S2, S3, S4, A1, A2, A3, A4 (you might login as admin for example and keep this in a private browser window)

      Login as student1:

      • Go to the direct URL for S1, S2, S3 and S4
      • Ensure that you have the message "Sorry, but you do not currently have permissions to do that (View hidden sections)."
      • Go to the direct URL for A1, A2, A3 and A4,
      • Ensure that you are redirected to the course index and have the message "Sorry, this activity is currently hidden"
      Show
      Create a course C1: Create a subsection S1 with an assignment activity A1 Create an assignment activity A2 in a section S2 (not subsection) Create a subsection S3 with an assignment activity A3 Create an assignment activity A4 in a section S4 (not subsection) Enroll a Student student1 Hide S1 Hide S2 Set restriction for S3 so it is visible on the day after today Set restriction for S4 so it is visible on the day after today Copy the direct URL for S1, S2, S3, S4, A1, A2, A3, A4 (you might login as admin for example and keep this in a private browser window) Login as student1: Go to the direct URL for S1, S2, S3 and S4 Ensure that you have the message "Sorry, but you do not currently have permissions to do that (View hidden sections)." Go to the direct URL for A1, A2, A3 and A4, Ensure that you are redirected to the course index and have the message "Sorry, this activity is currently hidden"
    • HQ 2024 Sprint I2.3 Moppies

      This issue is part of the course hierarch project.

      Issue goals

      Any content in a delegated section must also be checked in the parent context. This can be done in several ways. This task is about evaluate how to deal with this new subsection concept inside the activities and regarding the course capabilities.

      There are several approaches that must be evaluated:

      • Check if it is possible to infer the parent section form the context in the has_capacility function.
      • Create a get_context in the section_info class that will return the correct context to check capabilities
      • Create an ad-hoc method to check capabilities in a subsection
      • Any other creative solution we can think of.

      Future issues

      Any capabilities inside a subsection must first be checked by the delegated plugins.

       

            laurent.david@moodle.com Laurent David
            tusefomal Ferran Recio
            Ferran Recio Ferran Recio
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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

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