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

nopermissiontoupdatecalendar error when changing user event to course event

    XMLWordPrintable

Details

    • Bug
    • Status: Reopened
    • Minor
    • Resolution: Unresolved
    • 3.4.4
    • None
    • Calendar
    • MOODLE_34_STABLE

    Description

      When a user attempts to edit an existing User event that they created and change it to a Course event, in the context of a course where they have permission to change events, they receive the nopermissiontoupdatecalendar exception.

      Steps to reproduce:

      • Create a user event on the calendar
      • Edit the event and set it to type: course, and select a course from the dropdown list where the user is a teacher

      Expected: The event should be updated to be a course event, given that the user has manageentries capability in the user context and the course context.

      Actually happens: nopermissiontoupdatecalendar exception

      Stack trace: 

      Error code: nopermissiontoupdatecalendar

      • line 482 of /lib/setuplib.php: moodle_exception thrown
      • line 564 of /calendar/lib.php: call to print_error()
      • line 893 of /calendar/externallib.php: call to calendar_event->update()
      • line 228 of /lib/externallib.php: call to core_calendar_external::submit_create_update_form()
      • line 59 of /lib/ajax/service.php: call to external_api::call_external_function()

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              meltonml Michelle Melton
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              2 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated: