|
|
@@ -151,10 +151,19 @@ class PresenceReport extends Component
|
|
|
}
|
|
|
|
|
|
$membersQuery = \App\Models\MemberCourse::query()
|
|
|
+ ->with(['member', 'course.level'])
|
|
|
->whereIn('course_id', $slotCourseIds)
|
|
|
->whereDate('date_from', '<=', $calendar->from)
|
|
|
->whereDate('date_to', '>=', $calendar->from)
|
|
|
- ->with(['member', 'course.level']);
|
|
|
+ ->whereHas('member', function ($query) {
|
|
|
+ $query->where(function ($q) {
|
|
|
+ $q->where('is_archived', false)
|
|
|
+ ->orWhereNull('is_archived');
|
|
|
+ })->where(function ($q) {
|
|
|
+ $q->where('is_deleted', false)
|
|
|
+ ->orWhereNull('is_deleted');
|
|
|
+ });
|
|
|
+ });
|
|
|
|
|
|
if (!empty($this->search)) {
|
|
|
$s = trim(mb_strtolower($this->search));
|