MDL-67211 Tasks: Add cron_enabled setting.

Co-authored-by: Sam Marshall <[email protected]>
This commit is contained in:
Mikhail Golenkov
2020-08-25 17:08:57 +10:00
co-authored by Sam Marshall
parent 45875f6f7b
commit d7342dc239
12 changed files with 193 additions and 9 deletions
+10
View File
@@ -261,6 +261,16 @@ class tool_task_renderer extends plugin_renderer_base {
return $cell;
}
/**
* Displays a warning on the page if cron is disabled.
*
* @return string HTML code for information about cron being disabled
* @throws moodle_exception
*/
public function cron_disabled(): string {
return $this->output->notification(get_string('crondisabled', 'tool_task'), 'warning');
}
/**
* Renders a link back to the scheduled tasks page (used from the 'run now' screen).
*