From 49f60210ceceefdfaefe356d6e1fa9b458501811 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E7=90=A6?= Date: Wed, 28 Jan 2026 09:32:59 +0800 Subject: [PATCH] =?UTF-8?q?=E9=97=A8=E5=BA=97=E6=9F=A5=E8=AF=A2=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- platform/modules/v1/controllers/ErpController.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/platform/modules/v1/controllers/ErpController.php b/platform/modules/v1/controllers/ErpController.php index 88dd211..c553817 100644 --- a/platform/modules/v1/controllers/ErpController.php +++ b/platform/modules/v1/controllers/ErpController.php @@ -56,6 +56,8 @@ class ErpController extends Controller //解析成erp所需参数(订单详情是否需要改动 - 线上订单的展示) $erpData = []; $ids = []; + + $defaultUserId = '41677'; foreach($productOrders as $k=>$v){ // 如果是商城订单 if ($v['order_type'] == 2) { @@ -64,7 +66,7 @@ class ErpController extends Controller $erpData[$k]['createTime'] = date('Y-m-d H:i:s', $v['created_at']); // $erpData[$k]['userId'] = $v['store']['erp_id']; // 商城订单暂时都用11007诊所来接收订单 - $erpData[$k]['userId'] = '41677'; + $erpData[$k]['userId'] = $defaultUserId; $erpData[$k]['orderStatus'] = $v['status']; $erpData[$k]['orderType'] = $v['type']; $erpData[$k]['totalAmount'] = $v['total_pay_price']; @@ -115,7 +117,11 @@ class ErpController extends Controller if ($v['prescription']['status'] == 1) { $erpData[$k]['orderId'] = $v['order_no']; $erpData[$k]['createTime'] = date('Y-m-d H:i:s', $v['created_at']); - $erpData[$k]['userId'] = $v['store']['erp_id']; + if ($v['is_online'] == 3) { + $erpData[$k]['userId'] = $defaultUserId; + } else { + $erpData[$k]['userId'] = $v['store']['erp_id']; + } $erpData[$k]['orderStatus'] = $v['status']; $erpData[$k]['totalAmount'] = $v['total_pay_price']; // $erpData[$k]['deliveryAmount'] = $v['trans_expenses'];