This commit is contained in:
Adrian Greeve 2019-12-23 09:41:04 +08:00
commit 0c75251509
2 changed files with 6 additions and 0 deletions

View File

@ -43,6 +43,7 @@ $string['pluginname'] = 'Scheduled task configuration';
$string['resettasktodefaults'] = 'Reset task schedule to defaults';
$string['resettasktodefaults_help'] = 'This will discard any local changes and revert the schedule for this task back to its original settings.';
$string['runnow'] = 'Run now';
$string['runagain'] = 'Run again';
$string['runnow_confirm'] = 'Are you sure you want to run this task \'{$a}\' now? The task will run on the web server and may take some time to complete.';
$string['runpattern'] = 'Run pattern';
$string['scheduledtasks'] = 'Scheduled tasks';

View File

@ -92,6 +92,11 @@ $CFG->mtrace_wrapper = 'tool_task_mtrace_wrapper';
echo html_writer::end_tag('pre');
$output = $PAGE->get_renderer('tool_task');
// Re-run the specified task (this will output an error if it doesn't exist).
echo $OUTPUT->single_button(new moodle_url('/admin/tool/task/schedule_task.php',
array('task' => $taskname, 'confirm' => 1, 'sesskey' => sesskey())),
get_string('runagain', 'tool_task'));
echo $output->link_back();
echo $OUTPUT->footer();