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

Add access capability to Moodle Extras menu in 2.0 core

    XMLWordPrintable

Details

    • Improvement
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 2.0
    • None
    • Accessibility
    • None
    • MOODLE_20_STABLE

    Description

      request expansion of Moodle Custom Menu (MDL-22398) to include a visibility/access capability on the system level.

      Taken from thread <http://moodle.org/mod/forum/discuss.php?d=149803>

      ) check if a user has the capability to view the menu, something like this:

      if ($hascustommenu && has_capability(moodle/site:viewcustommenu)) {
      //display custom menu
      }

      so that I don't have to use the "legacy function" to hide it from guests/roles:

      if ($hascustommenu && !(has_capability(moodle/legacy:guest || has_capability(moodle/legacy:student))) {
      //display custom menu
      }

      Attachments

        Issue Links

          Activity

            People

              moodle.com moodle.com
              dwahl Daniel Wahl
              Andrew Lyons, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Stevani Andolo
              Votes:
              26 Vote for this issue
              Watchers:
              14 Start watching this issue

              Dates

                Created:
                Updated: