patient_record.patient_id
parent
3ce99c0d32
commit
90e76b0400
|
|
@ -206,7 +206,10 @@ class PatientRecordController extends AdminController
|
|||
public function getPatientOptions()
|
||||
{
|
||||
if (!$this->patientOptions) {
|
||||
$this->patientOptions = Patient::select(['id as value', 'name as label'])->sort()->get();
|
||||
$this->patientOptions = Patient::with(['type'])->orderBy('type_id')->sort()->get()->map(fn ($item) => [
|
||||
'label' => $item->type?->name.'--'.$item->name,
|
||||
'value' => $item->id,
|
||||
]);
|
||||
}
|
||||
|
||||
return $this->patientOptions;
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
return [
|
||||
'id' => 'ID',
|
||||
'patient_id' => '姓名',
|
||||
'patient_id' => '病人',
|
||||
'type_id' => '类别',
|
||||
'treat_at' => '诊疗时间',
|
||||
'admin_user_id' => '相关人员',
|
||||
|
|
|
|||
Loading…
Reference in New Issue