feat(treatment): filter treatment cases by patient record
The list could be narrowed by status, search and open-date, but not by patient — so a patient's own file had no way to ask which courses belong to them. `?record=` adds that bound. patientRecord is joined once and shared with the search branch; joining it twice under the same alias is a DQL error, and search already needed it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -59,6 +59,8 @@ class TreatmentCaseController extends BaseController
|
||||
$q !== '' ? $q : null,
|
||||
$this->dayBoundary($request->query->get('from'), '00:00:00'),
|
||||
$this->dayBoundary($request->query->get('to'), '23:59:59'),
|
||||
// نمای «پروندهٔ بیمار» همین فهرست است با یک کران بیشتر.
|
||||
is_string($record = $request->query->get('record')) && $record !== '' ? $record : null,
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user