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

Remove "add group/grouping access restriction" button when FEATURE_GROUPS is not supported

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Edit the file: mod/choice/lib.php and find the choice_supports() function
      2. Change FEATURE_GROUPS to false, but leave FEATURE_GROUPINGS set to true.
      3. Now, in your Moodle site, create a new Choice activity, scroll down to the common module settings and expand that section.
      4. Confirm you see only 2 elements: Availability and ID number
      5. Confirm you DO NOT see a disabled button titled 'Add group/grouping access restriction'
      Show
      Edit the file: mod/choice/lib.php and find the choice_supports() function Change FEATURE_GROUPS to false, but leave FEATURE_GROUPINGS set to true. Now, in your Moodle site, create a new Choice activity, scroll down to the common module settings and expand that section. Confirm you see only 2 elements: Availability and ID number Confirm you DO NOT see a disabled button titled 'Add group/grouping access restriction'
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_33_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE, MOODLE_36_STABLE
    • Fixed Branches:
      MOODLE_34_STABLE, MOODLE_35_STABLE
    • Pull from Repository:
    • Pull 3.5 Branch:
    • Pull Master Branch:
      MDL-60145-master

      Description

      When you add/edit a module, in some configurations, an "add group/grouping access restriction" button in "common module settings" section is displayed as disabled, but can't, in any way, be active.

      1. find a module that allow groupings but not groups (or edit an existing module like mod_choice and edit mod/choice/lib.php and change in choice_supports() function this line : case FEATURE_GROUPS: return false;)
      2. add a new instance of this module in your course

      actual result :

      1. in "common module settings" section, you should have a disabled button named "add group/grouping access restriction"

      expected result :

      1. in "common module settings" section, you should not have a disabled button named "add group/grouping access restriction"

        Attachments

          Activity

            People

            Assignee:
            jaked Jake Dallimore
            Reporter:
            jboulen Julien Boulen
            Peer reviewer:
            Carlos Escobedo
            Integrator:
            Eloy Lafuente (stronk7)
            Tester:
            Janelle Barcega
            Participants:
            Component watchers:
            Sam Marshall, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              12/Nov/18

                Time Tracking

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 20 minutes
                20m