mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDL-40358 Enrolments: Fixed sql when user is suspended
This commit is contained in:
parent
cb88ffb698
commit
117e94a050
1 changed files with 2 additions and 2 deletions
|
@ -302,8 +302,8 @@ class course_enrolment_manager {
|
|||
'now1' => $now,
|
||||
'now2' => $now);
|
||||
} else if ($this->statusfilter === ENROL_USER_SUSPENDED) {
|
||||
$sql .= " AND ue.status = :inactive OR e.status = :disabled OR ue.timestart > :now1
|
||||
OR (ue.timeend <> 0 AND ue.timeend < :now2)";
|
||||
$sql .= " AND (ue.status = :inactive OR e.status = :disabled OR ue.timestart > :now1
|
||||
OR (ue.timeend <> 0 AND ue.timeend < :now2))";
|
||||
$now = round(time(), -2); // rounding helps caching in DB
|
||||
$params += array('disabled' => ENROL_INSTANCE_DISABLED,
|
||||
'inactive' => ENROL_USER_SUSPENDED,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue