From b289d2627f523baabcad81a4c09edc04b09bfbb1 Mon Sep 17 00:00:00 2001 From: Devil Date: Mon, 13 Sep 2021 12:33:35 +0800 Subject: [PATCH] =?UTF-8?q?=20=E8=AE=A2=E5=8D=95=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E5=A4=84=E7=90=86=E9=80=BB=E8=BE=91=20=E6=8B=86=E5=88=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/service/BuyService.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/service/BuyService.php b/app/service/BuyService.php index 90166702b..4fc2cf3c5 100755 --- a/app/service/BuyService.php +++ b/app/service/BuyService.php @@ -1232,9 +1232,10 @@ class BuyService { throw new \Exception('订单添加失败'); } + $order['id'] = $order_id; // 订单详情添加 - foreach($v['detail_data'] as $vs) + foreach($v['detail_data'] as &$vs) { // 添加订单详情数据,data返回自增id $order_detail_id = 0; @@ -1242,6 +1243,7 @@ class BuyService if($ret['code'] == 0) { $order_detail_id = $ret['data']; + $vs['id'] = $order_detail_id; } else { throw new \Exception($ret['msg']); }