Improve execution of health care sheet v2

This commit is contained in:
Djery-Tom 2021-12-20 12:26:51 +01:00
parent c689b89cb0
commit bad3b7bca8
1 changed files with 2 additions and 1 deletions

View File

@ -1003,7 +1003,8 @@ class HealthCareSheetController extends Controller
return $q->with(['act:id,code,name'])->where('billed', 0); return $q->with(['act:id,code,name'])->where('billed', 0);
}, 'prescriptions' => function ($q) { }, 'prescriptions' => function ($q) {
return $q->with(['drug_or_device:id,name'])->where('billed', 0); return $q->with(['drug_or_device:id,name'])->where('billed', 0);
}])->where('user_id', $request->input('user_id')); }])->where('state', InsuranceSubscriptionState::ACCEPTED)
->where('user_id', $request->input('user_id'));
} }
if (!empty($type)) { if (!empty($type)) {