MDL-47480 tasks: Define order for getting tasks
This commit is contained in:
@@ -448,7 +448,8 @@ class manager {
|
||||
|
||||
$where = "(lastruntime IS NULL OR lastruntime < :timestart1)
|
||||
AND (nextruntime IS NULL OR nextruntime < :timestart2)
|
||||
AND disabled = 0";
|
||||
AND disabled = 0
|
||||
ORDER BY lastruntime, id ASC";
|
||||
$params = array('timestart1' => $timestart, 'timestart2' => $timestart);
|
||||
$records = $DB->get_records_select('task_scheduled', $where, $params);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user