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

Deleting the last category in a context gives an error - you should not be allowed to get that far

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.6.6, 2.7.3, 2.8.1
    • Fix Version/s: 2.7.5, 2.8.3
    • Component/s: Questions
    • Labels:
    • Testing Instructions:
      Hide
      1. Create a new course 'C1'.
      2. Go to Question bank -> Categories.
      3. Make a new subcategory 'Subcategory' of the category 'Default for C1'.
      4. Verify that there is no delete icon next to 'Default for C1'.
      5. Click the left arrow next to 'Subcategory' to promote it to the top level.
      6. Verify that both categories now have a delete icon.
      Show
      Create a new course 'C1'. Go to Question bank -> Categories. Make a new subcategory 'Subcategory' of the category 'Default for C1'. Verify that there is no delete icon next to 'Default for C1'. Click the left arrow next to 'Subcategory' to promote it to the top level. Verify that both categories now have a delete icon.
    • Affected Branches:
      MOODLE_26_STABLE, MOODLE_27_STABLE, MOODLE_28_STABLE
    • Fixed Branches:
      MOODLE_27_STABLE, MOODLE_28_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      Steps to reproduce:

      1. Create a new course 'C1'.
      2. Go to Question bank -> Categories.
      3. Make a new subcategory 'Subcategory' of the category 'Default for C1'.

      Expected result:

      • There should not be a delete icon next to 'Default for C1'.

      Acutal result:

      • That icon is present.
      • When you click it, you get a fatal error telling you that you cannot delete that category because it is the default.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  2/Feb/15