Commit 519185e6 by 赵增煜

处方详情

parent aa5a824a
......@@ -41,7 +41,7 @@ protected function grid()
}
$grid->model()->orderBy('id', 'DESC');
$grid->model()->where('pharmacy_id', Admin::user()->pharmacy_id);
$grid->column('id', '处方单编号')->sortable();
$grid->column('status','处方状态')->using(PrescriptionModel::PRESCRIPTION_STATUS_MAP)->badge(PrescriptionModel::PRESCRIPTION_STATUS_MAP_COLOR);
$grid->column('prescription_type','处方类型')->using(PrescriptionModel::PRESCRIPTION_TYPE_MAP);
......@@ -128,51 +128,51 @@ protected function detail($id)
return Show::make($id, new PrescriptionRepository(), function (Show $show) {
$show->field('id')->width(3);
$show->field('status')->width(3)->using(PrescriptionModel::PRESCRIPTION_STATUS_MAP);
$show->field('status', '处方状态')->width(3)->using(PrescriptionModel::PRESCRIPTION_STATUS_MAP);
$show->field('patient_name')->width(3);
$show->field('patient_name', '患者姓名')->width(3);
$show->field('patient_age')->width(3);
$show->field('patient_gender')->using(PatientModel::SEX_MAP)->width(3);
$show->field('diagnosis_name')->width(3);
$show->field('patient_age', '患者年龄')->width(3);
$show->field('patient_gender', '患者性别')->using(PatientModel::SEX_MAP)->width(3);
$show->field('diagnosis_name', '诊断')->width(3);
$show->field('inquiry_info')->width(3)->as(function ($inquiryInfo) {
$show->field('inquiry_info', '问诊问题')->width(3)->as(function ($inquiryInfo) {
$answerMap = [1 => '是', 0 => '否'];
return array_map(function ($item) use ($answerMap) {
return $item['question'].' : '.$answerMap[$item['answer']];
}, $inquiryInfo);
})->label();
$show->field('drug_info')->width(3)->as(function ($drugInfo) {
$show->field('drug_info', '用药信息')->width(3)->as(function ($drugInfo) {
return array_map(function ($item) {
return $item['drug_name'].' : '.($item['spec'] ?? '').' : '.$item['num'].($item['unit'] ?? '').' : '.($item['dosage_desc'] ?? '');
}, $drugInfo);
})->label();
$show->field('doctor_name')->width(3);
$show->field('doctor_name', '医生姓名')->width(3);
$show->field('doctor_online_hospital_name')->width(3);
$show->field('doctor_department')->width(3);
$show->field('doctor_title')->width(3);
$show->field('doctor_online_hospital_name', '医师互联网医院名称')->width(3);
$show->field('doctor_department', '医师科室')->width(3);
$show->field('doctor_title', '医师职称')->width(3);
$show->field('doctor_license_no')->width(3);
$show->field('doctor_signed_pic')->image('', 100, 100)->width(3);
$show->field('doctor_introduction')->width(3);
$show->field('doctor_license_no', '医师执照编号')->width(3);
$show->field('doctor_signed_pic', '医师签名照')->image('', 100, 100)->width(3);
$show->field('doctor_introduction', '医师简介')->width(3);
$show->field('pharmacy_name')->width(3);
$show->field('pharmacist_name')->width(3);
$show->field('pharmacist_license_number')->width(3);
$show->field('pharmacy_name', '药店名称')->width(3);
$show->field('pharmacist_name', '药师姓名')->width(3);
$show->field('pharmacist_license_number', '药师执照编号')->width(3);
$show->field('pharmacist_signed_pic')->image('', 100, 100)->width(3);
$show->field('prescription_pic')->image('', 100, 100)->width(3);
$show->field('prescription_pic_eseal')->image('', 100, 100)->width(3);
$show->field('pharmacist_signed_pic', '药师签名照')->image('', 100, 100)->width(3);
# $show->field('prescription_pic','处方单图片地址')->image('', 100, 100)->width(3);
# $show->field('prescription_pic_eseal')->image('', 100, 100)->width(3);
$show->field('prescription_at')->width(3);
$show->field('review_at')->width(3);
$show->field('open_source')->width(3)->using(PrescriptionModel::OPEN_SOURCE_MAP);
$show->field('prescription_at', '开方时间')->width(3);
$show->field('review_at', '审方时间')->width(3);
$show->field('open_source', '开方来源')->width(3)->using(PrescriptionModel::OPEN_SOURCE_MAP);
$show->field('is_voided')->width(3)->using(PrescriptionModel::IS_VOIDED_MAP);
$show->field('is_abnormal')->width(3)->using([0 => '否', 1 => '是']);
$show->field('prescription_type')->width(3)->using(PrescriptionModel::PRESCRIPTION_TYPE_MAP);
$show->field('is_voided', '是否作废')->width(3)->using(PrescriptionModel::IS_VOIDED_MAP);
$show->field('is_abnormal', '是否异常')->width(3)->using([0 => '否', 1 => '是']);
$show->field('prescription_type', '处方类型')->width(3)->using(PrescriptionModel::PRESCRIPTION_TYPE_MAP);
$show->panel()->tools(function ($tools) {
$tools->disableEdit();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment