Browse Source

Merge branch 'master' into dev

gorden 4 tháng trước cách đây
mục cha
commit
620783338a
1 tập tin đã thay đổi với 3 bổ sung2 xóa
  1. 3 2
      app/admin/controller/order/WholeController.php

+ 3 - 2
app/admin/controller/order/WholeController.php

@@ -793,6 +793,7 @@ class WholeController extends Curd
 
         $order = Order::where('order_id', $params['order_id'])->first();
         $oldOrderPaymentStatus = $order->order_status_payment;
+        $oldOrderSystemStatus = $order->order_status_system;
         if (!$order) {
             return json_fail('订单异常');
         }
@@ -1074,7 +1075,7 @@ class WholeController extends Curd
                 if (in_array($prefix, [10, 11, 12, 13, 14, 15])) {
                     $params['pay_category'] = 'WXPAY';
                     if ((!isset($result['return_code']) || $result['return_code'] != 'SUCCESS') || (!isset($result['result_code']) || $result['result_code'] != 'SUCCESS') || (empty($result['trade_state']) || $result['trade_state'] != 'SUCCESS')) {
-                        $order->order_status_system = $oldOrderPaymentStatus;
+                        $order->order_status_system = $oldOrderSystemStatus;
                         $order->order_status_payment = 'PENDING';
                         $order->order_is_complete = 'N';
 //                        Db::rollBack();
@@ -1086,7 +1087,7 @@ class WholeController extends Curd
                 } else if (in_array($prefix, [25, 26, 27, 28, 29, 30])) {
                     $params['pay_category'] = 'ALIPAY';
                     if ((!isset($result['code']) || $result['code'] != '10000') || (empty($result['trade_status']) || $result['trade_status'] != 'TRADE_SUCCESS')) {
-                        $order->order_status_system = $oldOrderPaymentStatus;
+                        $order->order_status_system = $oldOrderSystemStatus;
                         $order->order_status_payment = 'PENDING';
                         $order->order_is_complete = 'N';
 //                        Db::rollBack();