rabin 18 giờ trước cách đây
mục cha
commit
9433dae8dd

+ 1 - 1
src/place/order/app/Lib/Role/Pay.php

@@ -35,7 +35,7 @@ class Pay extends Core
             'promotion' => $detail['promotion'],
             'promotion_text' => $detail['promotion_text'],
         ];
-        if (count($this->detail) < 3) {
+        if (count($this->detail) < 1) {
             $this->order['name'][$detail['id']] = $detail['name'];
         }
         $this->order['cash'] += $detail['price'] * $detail['buy_num'];

+ 1 - 1
src/place/order/app/Lib/Source/Pay.php

@@ -66,7 +66,7 @@ class Pay extends Core
                 }
             }
         }
-        if (count($this->detail) < 3) {
+        if (count($this->detail) < 1) {
             $this->order['name'][$source['id']] = $source['name'];
         }
         $this->order['cash'] += $detail['price'] * $detail['buy_num'];

+ 9 - 5
src/place/set/app/Lib/Account.php

@@ -20,12 +20,16 @@ class Account
         if (!$cert || ($cert && $cert['edate'] <= time())) {
             Dever::load(\Api\Lib\Account::class)->run($account, 'task', [], 1, 'run', 'place');
         }
+        $param = [];
+        $param['cash'] = $result['cash'];
+        $param['order_num'] = $result['order_num'];
+        $param['openid'] = $result['openid'];
+        $param['name'] = $order['name'];
+        $param['notify'] = $order['notify'];
+        $param['cash'] = $order['pay_money_cash']*100;
+        $param['time_expire'] = time() + 4000;
 
-        $order['openid'] = $result['openid'];
-        $order['cash'] = $order['pay_money_cash']*100;
-        $order['time_expire'] = time() + 4000;
-
-        return Dever::load(\Api\Lib\Account::class)->run($account, 'order', $order, $env, 'run', 'place');
+        return Dever::load(\Api\Lib\Account::class)->run($account, 'order', $param, $env, 'run', 'place');
     }
 
     # 退款操作