@@ -1998,6 +1998,25 @@ class PatientOrderService extends BaseService
|
||||
$order_prescription = OrderPrescription::getWithPage($params, ['*'], $page, $per_page);
|
||||
if (!empty($order_prescription['data'])) {
|
||||
foreach ($order_prescription['data'] as &$item) {
|
||||
|
||||
//处理抄方情况
|
||||
$params = array();
|
||||
$params['order_inquiry_id'] = $item['order_inquiry_id'];
|
||||
$OrderInquiry = OrderInquiry::getOne($params);
|
||||
if (!empty($OrderInquiry)) {
|
||||
//为抄方订单
|
||||
if (!empty($OrderInquiry['transfer_doctor_id'])) {
|
||||
$params = array();
|
||||
$params['doctor_id'] = $OrderInquiry['transfer_doctor_id'];
|
||||
$fields = ['doctor_id','user_name','doctor_title'];
|
||||
|
||||
$UserDoctor = UserDoctor::getOne($params, $fields);
|
||||
if (!empty($UserDoctor)) {
|
||||
$item['UserDoctor'] = $UserDoctor->toArray();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($item['UserDoctor'])) {
|
||||
$item['UserDoctor']['doctor_title'] = DoctorTitleCode::getMessage($item['UserDoctor']['doctor_title']);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user