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

Install is shown despite user not having moodle/community:download

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.5.2
    • 2.5.3
    • Hub
    • MOODLE_25_STABLE
    • MOODLE_25_STABLE
    • Hide

      1) Add a 'Community finder' block to a course.
      2) Switch role to a Non-editing teacher (by default they have moodle/community:add but not moodle/community:download)
      3) Click search in the block
      4) In the search form, type "test" as the search term and click search
      5) When the results load up, the possible buttons on each should be "Save a link to this site" and "visit institution". NOT "Install".

      Testing when you have download cap:
      6) Switch role to Teacher (which has both caps).
      7) Search again, the results this time should have buttons "Install" and "visit demo"

      Show
      1) Add a 'Community finder' block to a course. 2) Switch role to a Non-editing teacher (by default they have moodle/community:add but not moodle/community:download) 3) Click search in the block 4) In the search form, type "test" as the search term and click search 5) When the results load up, the possible buttons on each should be "Save a link to this site" and "visit institution". NOT "Install". Testing when you have download cap: 6) Switch role to Teacher (which has both caps). 7) Search again, the results this time should have buttons "Install" and "visit demo"

    Description

      The moodle/community:download capability defines if a user is able to download courses from the community hub.

      However, when a user doesn't have this, they're still presented the 'install' button and search assumes they're looking for courses to download rather than ones to enrol in.

      Clicking install simply refreshes on the search screen because you don't have the capability which is good, but confusing for the user.

      Also included in the proposed fix is a $mform->setType call the formslib complains about.

      Attachments

        Issue Links

          Activity

            People

              aolley Adam Olley
              aolley Adam Olley
              Jérôme Mouneyrac Jérôme Mouneyrac
              Damyon Wiese Damyon Wiese
              Frédéric Massart Frédéric Massart
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                11/Nov/13