mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-32932: Add quickgrading support to mod_assign
This commit is contained in:
parent
a769a00157
commit
bf78ebd650
10 changed files with 437 additions and 58 deletions
|
@ -86,6 +86,24 @@ class mod_assign_renderer extends plugin_renderer_base {
|
|||
$table->data[] = $row;
|
||||
}
|
||||
|
||||
/**
|
||||
* Render a grading error notification
|
||||
* @param assign_quickgrading_result $result The result to render
|
||||
* @return string
|
||||
*/
|
||||
public function render_assign_quickgrading_result(assign_quickgrading_result $result) {
|
||||
$o = '';
|
||||
$o .= $this->output->heading(get_string('quickgradingresult', 'assign'), 4);
|
||||
|
||||
$o .= $this->output->notification($result->message);
|
||||
|
||||
$o .= $this->output->continue_button(new moodle_url('/mod/assign/view.php',
|
||||
array('id' => $result->coursemoduleid,
|
||||
'action'=>'grading')));
|
||||
|
||||
return $o;
|
||||
}
|
||||
|
||||
/**
|
||||
* Render the generic form
|
||||
* @param assign_form $form The form to render
|
||||
|
@ -93,6 +111,9 @@ class mod_assign_renderer extends plugin_renderer_base {
|
|||
*/
|
||||
public function render_assign_form(assign_form $form) {
|
||||
$o = '';
|
||||
if ($form->jsinitfunction) {
|
||||
$this->page->requires->js_init_call($form->jsinitfunction, array());
|
||||
}
|
||||
$o .= $this->output->box_start('boxaligncenter ' . $form->classname);
|
||||
$o .= $this->moodleform($form->form);
|
||||
$o .= $this->output->box_end();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue