From 3649f1635d07db8e7852c97b1b965b8e17e0b8b7 Mon Sep 17 00:00:00 2001 From: wucongxing <815046773@qq.com> Date: Mon, 7 Aug 2023 14:23:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=9B=BE=E7=89=87=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Request/SafeRequest.php | 2 +- app/Services/DetectionService.php | 5 ++--- app/Services/PatientOrderService.php | 4 ++-- app/Services/SafeService.php | 4 ++++ config/routes.php | 2 +- 5 files changed, 10 insertions(+), 7 deletions(-) diff --git a/app/Request/SafeRequest.php b/app/Request/SafeRequest.php index 72e2e2e..0759d3d 100644 --- a/app/Request/SafeRequest.php +++ b/app/Request/SafeRequest.php @@ -31,7 +31,7 @@ class SafeRequest extends FormRequest { return [ 'user_type' => 'required|integer|min:1|max:3', - 'scene' => 'required|integer|min:1|max:2', + 'scene' => 'required|integer|min:1|max:3', ]; } diff --git a/app/Services/DetectionService.php b/app/Services/DetectionService.php index df30d9a..622a517 100644 --- a/app/Services/DetectionService.php +++ b/app/Services/DetectionService.php @@ -313,7 +313,7 @@ class DetectionService extends BaseService if (!empty($order_detection)){ $result['status'] = 2; $result['message'] = "当前患者存在未完成的检测订单"; - $result['data']['order_detection_id'] = $order_detection['order_detection_id']; + $result['data']['order_no'] = $order_detection['detection_no']; return success($result); } @@ -490,8 +490,7 @@ class DetectionService extends BaseService return success(); } - return success($order_detection['order_detection_id']); - + return success($order_detection['detection_no']); } // 绑定检测管 diff --git a/app/Services/PatientOrderService.php b/app/Services/PatientOrderService.php index 9dbc50e..edb239a 100644 --- a/app/Services/PatientOrderService.php +++ b/app/Services/PatientOrderService.php @@ -1650,12 +1650,12 @@ class PatientOrderService extends BaseService { $user_info = $this->request->getAttribute("userInfo") ?? []; - $order_detection_id = $this->request->route('order_detection_id'); + $order_no = $this->request->route('order_no'); // 获取订单数据 $params = array(); $params['patient_id'] = $user_info['client_user_id']; - $params['order_detection_id'] = $order_detection_id; + $params['detection_no'] = $order_no; $params['is_delete'] = 0; $order_detection = OrderDetection::getOne($params); if (empty($order_detection)) { diff --git a/app/Services/SafeService.php b/app/Services/SafeService.php index a2bf80c..bb7c976 100644 --- a/app/Services/SafeService.php +++ b/app/Services/SafeService.php @@ -52,6 +52,10 @@ class SafeService extends BaseService // 名片 $dir = $dir . 'card/'; break; + case 4: + // 检测管 + $dir = $dir . 'detection/'; + break; default: // code... diff --git a/config/routes.php b/config/routes.php index f7f92e7..1c6ab4e 100644 --- a/config/routes.php +++ b/config/routes.php @@ -448,7 +448,7 @@ Router::addGroup('/patient', function () { Router::get('', [PatientOrderController::class, 'getPatientDetectionOrderList']); // 获取患者检测订单详情 - Router::get('/{order_detection_id:\d+}', [PatientOrderController::class, 'getPatientDetectionOrderInfo']); + Router::get('/{order_no:\d+}', [PatientOrderController::class, 'getPatientDetectionOrderInfo']); // 删除检测订单 Router::delete('/{order_detection_id:\d+}', [PatientOrderController::class, 'deletePatientDetectionOrder']);