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

Role permissions on blocks on dashboard are ignored.

XMLWordPrintable

    • MOODLE_34_STABLE, MOODLE_35_STABLE

      I want only particular users to be able to view a block on their dashboard. I create a new role for this purpose. The role is not allowed to view a block and can be assigned at block context. I add the block to the default dashboard page, and assign a number of users the role that is not allowed to view the block.

      I check the permissions for one of these users. 'View Block' is set to 'no'. However, they are able to view the block.

       

       

       To replicate

      Create Role

      1. Site Admin - Users - Permissions - Define Roles 

      2. Click Add a New Role

      3. Choose 'No Role' as the arch type

      4. Give it a name (ie. Dashboard Mask)

      5. Check off  "Block" context

      6. Leave everything else as "not set" and scroll down to the bottom of the page where you see the "Block" section: 

           Change the following three permissions to "Prohibit": 

           "Edit a Block's settings"

           "View Block"

           "Manage Blocks on a Page"     

      8. Click save changes. 

      Assign the role in the block

      1. Site Admin - Appearance - Default Dashboard page

      2. Click "Blocks Editing On"

      3. In the Course Overview Block, click the Cog and select "Assign Roles"

      4. You'll see your Daskboard Mask listed and a '0' - click on "Dashboard Mask"

      5. Add all users who you don't want to see the block

      7. Navigate back to Site Admin - Appearance - Default Dashboard page

      8. Click "Reset Dashboard for all users"

       

      Result

      Block permissions show that one of the affected users cannot see the block

       

      However, logging in as the user confirms that they can in fact see the block.

       

            Unassigned Unassigned
            cathkdsc C Behan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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