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

Replace add_to_log with an event trigger - role

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Major Major
    • 2.6
    • 2.5
    • Events API, Logging
    • MOODLE_25_STABLE
    • MOODLE_26_STABLE
    • wip-mdl-40044
    • Hide
      1. Run phpunit lib/tests/accesslib_test.php
      2. Go to Define roles page (Site administration -> Users -> Permissions -> Define roles). Try change and save settings in each tab. You should not see any problem.
      3. Try change roles capability in course and system level and make sure you don't get any error/notice.
      Show
      Run phpunit lib/tests/accesslib_test.php Go to Define roles page (Site administration -> Users -> Permissions -> Define roles). Try change and save settings in each tab . You should not see any problem. Try change roles capability in course and system level and make sure you don't get any error/notice.
    • 13
    • BACKEND Sprint 3

      Replace the add_to_log calls for the following area, with a call to the get_legacy_logdata function in the event class.

      role
      /admin/roles/manage.php:93: add_to_log(SITEID, 'role', 'delete', 'admin/roles/manage.php', $roles[$roleid]>localname, '', $USER>id);
      /admin/roles/override.php:128: add_to_log($course->id, 'role', 'override', 'admin/roles/override.php?contextid='.$context->id.'&roleid='.$roleid, $rolename, '', $USER->id);
      /admin/roles/assign.php:114: add_to_log($course->id, 'role', 'assign', 'admin/roles/assign.php?contextid='.$context->id.'&roleid='.$roleid, $rolename, '', $USER->id);
      /admin/roles/assign.php:134: add_to_log($course->id, 'role', 'unassign', 'admin/roles/assign.php?contextid='.$context->id.'&roleid='.$roleid, $rolename, '', $USER->id);
      /admin/roles/define.php:199: add_to_log(SITEID, 'role', $action, 'admin/roles/define.php?action=view&roleid=' .
      /admin/roles/allow.php:49: add_to_log(SITEID, 'role', 'edit allow ' . $mode, str_replace($CFG->wwwroot . '/', '', $baseurl), '', '', $USER->id);
      /lib/accesslib.php:1524: add_to_log(SITEID, 'role', 'delete', 'admin/roles/action=delete&roleid='.$roleid, $rolename, '');

            rajeshtaneja Rajesh Taneja
            abgreeve Adrian Greeve
            Frédéric Massart Frédéric Massart
            Dan Poltawski Dan Poltawski
            Sam Hemelryk Sam Hemelryk
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.