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

event mod_deleted is NOT triggered when delete mod through AJAX

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.1
    • Fix Version/s: 2.0.5, 2.1.2
    • Component/s: Course
    • Labels:
      None
    • Testing Instructions:
      Hide

      suitable for developers only:
      1/ create local plugin that handles the 'mod_deleted' event
      2/ verify it is triggered both via ajax and normal delete of activity

      Show
      suitable for developers only: 1/ create local plugin that handles the 'mod_deleted' event 2/ verify it is triggered both via ajax and normal delete of activity
    • Workaround:
      Hide

      See patch. The code is totally copied from course/mod.php

      Show
      See patch. The code is totally copied from course/mod.php
    • Affected Branches:
      MOODLE_21_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE

      Description

      When in editing mode and AJAX is enabled, clicking the delete mod icon will request course/rest.php. It does remove the mod properly but forgets to trigger mod_deleted event.

      Any other modules depend on this event will not work.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

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

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    10/Oct/11