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

Replace add_to_log with an event trigger - mod_assignment

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major
    • Resolution: Deferred
    • Affects Version/s: 2.5
    • Fix Version/s: None
    • Component/s: Events API, Logging
    • Labels:
    • Story Points:
      40
    • Sprint:
      BACKEND Sprint 7

      Description

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

      mod/assignment (17 calls)
      /mod/assignment/index.php:16: add_to_log($course->id, "assignment", "view all", "index.php?id=$course->id", "");
      /mod/assignment/type/uploadsingle/assignment.class.php:68: add_to_log($this->course->id, "assignment", "view", "view.php?id={$this->cm->id}", $this->assignment->id, $this->cm->id);
      /mod/assignment/type/uploadsingle/assignment.class.php:239: add_to_log($this->course->id, 'assignment', 'upload', 'view.php?a='.$this->assignment->id, $this->assignment->id, $this->cm->id);
      /mod/assignment/type/upload/assignment.class.php:49: add_to_log($this->course->id, 'assignment', 'view', "view.php?id={$this->cm->id}", $this->assignment->id, $this->cm->id);
      /mod/assignment/type/upload/assignment.class.php:449: add_to_log($this->course->id, 'assignment', 'upload', 'view.php?a='.$this->assignment->id, $this->assignment->id, $this->cm->id);
      /mod/assignment/type/upload/assignment.class.php:515: add_to_log($this->course->id, 'assignment', 'upload',
      /mod/assignment/type/upload/assignment.class.php:636: add_to_log($this->course->id, 'assignment', 'upload', //TODO: add finalize action to log
      /mod/assignment/type/upload/assignment.class.php:676: add_to_log($this->course->id, 'assignment', 'upload', //TODO: add finalize action to log
      /mod/assignment/type/upload/assignment.class.php:704: add_to_log($this->course->id, 'assignment', 'view submission', 'submissions.php?id='.$this->cm->id.'&userid='.$userid.'&mode='.$mode.'&offset='.$offset, $this->assignment->id, $this->cm->id);
      /mod/assignment/type/upload/assignment.class.php:820: add_to_log($this->course->id, 'assignment', 'upload', //TODO: add delete action to log
      /mod/assignment/type/online/assignment.class.php:78: add_to_log($this->course->id, 'assignment', 'upload', 'view.php?a='.$this->assignment->id, $this->assignment->id, $this->cm->id);
      /mod/assignment/type/online/assignment.class.php:86: add_to_log($this->course->id, "assignment", "view", "view.php?id={$this->cm->id}", $this->assignment->id, $this->cm->id);
      /mod/assignment/type/offline/assignment.class.php:96: add_to_log($this->course->id, 'assignment', 'update grades',
      /mod/assignment/lib.php:159: add_to_log($this->course->id, "assignment", "view", "view.php?id={$this->cm->id}",
      /mod/assignment/lib.php:777: add_to_log($this->course->id, 'assignment', 'update grades',
      /mod/assignment/lib.php:1248: add_to_log($course->id, 'assignment', 'view submission', 'submissions.php?id='.$this->cm->id, $this->assignment->id, $this->cm->id);
      /mod/assignment/lib.php:1795: add_to_log($this->course->id, 'assignment', 'update grades',

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              skodak Petr Skoda
              Reporter:
              abgreeve Adrian Greeve
              Participants:
              Component watchers:
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona), Andrew Lyons, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: