Fixed many feature failures around preferences, route coverage, administrator enrollment, assignment section names, attendance tracking controller access, finance PDF generation, and finance notification logging.
API CI/CD / Validate (composer + pint) (push) Successful in 3m15s
API CI/CD / Test (PHPUnit) (push) Failing after 5m4s
API CI/CD / Build frontend assets (push) Successful in 1m3s
API CI/CD / Security audit (push) Failing after 49s
API CI/CD / Deploy to shared hosting (PHP) (push) Has been skipped
API CI/CD / Validate (composer + pint) (push) Successful in 3m15s
API CI/CD / Test (PHPUnit) (push) Failing after 5m4s
API CI/CD / Build frontend assets (push) Successful in 1m3s
API CI/CD / Security audit (push) Failing after 49s
API CI/CD / Deploy to shared hosting (PHP) (push) Has been skipped
This commit is contained in:
+12
-5
@@ -186,11 +186,18 @@ class Student extends BaseModel
|
||||
|
||||
// Students are global identities; year rosters come from yearly class/enrollment rows.
|
||||
if ($schoolYear !== null && strtolower($schoolYear) !== 'all') {
|
||||
$q->whereExists(function ($sub) use ($schoolYear) {
|
||||
$sub->selectRaw('1')
|
||||
->from('student_class as sc')
|
||||
->whereColumn('sc.student_id', 'students.id')
|
||||
->where('sc.school_year', $schoolYear);
|
||||
$q->where(function ($yearQuery) use ($schoolYear) {
|
||||
$yearQuery->whereExists(function ($sub) use ($schoolYear) {
|
||||
$sub->selectRaw('1')
|
||||
->from('student_class as sc')
|
||||
->whereColumn('sc.student_id', 'students.id')
|
||||
->where('sc.school_year', $schoolYear);
|
||||
})->orWhereExists(function ($sub) use ($schoolYear) {
|
||||
$sub->selectRaw('1')
|
||||
->from('enrollments as e')
|
||||
->whereColumn('e.student_id', 'students.id')
|
||||
->where('e.school_year', $schoolYear);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user