MDL-41101 mod_assign: replaced 'view submit assignment form' add_to_log call with an event

This commit is contained in:
Mark Nelson 2014-03-24 19:32:22 -07:00 committed by Petr Skoda
parent 7eda466cb9
commit e65221c27b
4 changed files with 132 additions and 1 deletions

View file

@ -3349,7 +3349,16 @@ class assign {
$o .= $this->get_renderer()->render(new assign_form('editsubmissionform', $mform));
$o .= $this->view_footer();
$this->add_to_log('view submit assignment form', $title);
$event = \mod_assign\event\submission_form_viewed::create(array(
'relateduserid' => $userid,
'context' => $this->get_context(),
'other' => array(
'assignid' => $this->get_instance()->id
)
));
$event->set_legacy_logdata('view submit assignment form', $title);
$event->trigger();
return $o;
}