Parcourir la source

话费充值使用慢充

xialei il y a 1 an
Parent
commit
30a243ab70
2 fichiers modifiés avec 3 ajouts et 4 suppressions
  1. 2 3
      app/controller/api/Notify.php
  2. 1 1
      app/controller/api/store/service/Huafei.php

+ 2 - 3
app/controller/api/Notify.php

@@ -63,10 +63,9 @@ class Notify
63 63
                             }
64 64
                             //话费充值支付成功推送
65 65
                             try{
66
-                                $Huafei = new Huafei();
67
-                                $pay_wx = systemConfig('pay_wx');
68
-                                $push = $Huafei->pushHf($order_data['uid'], $order_data['order_no'], $order_data['mobile'], $order_data['pay_price']);
66
+                                $push = app()->make(Huafei::class)->pushHf($order_data['uid'], $order_data['order_no'], $order_data['mobile'], $order_data['pay_price']);
69 67
                                 if($push['code'] != '0000'){
68
+                                    $pay_wx = systemConfig('pay_wx');
70 69
                                     //推送失败 给新支付的这一笔退款
71 70
                                     Db::name('log')->insert(['data' => '给新话费充值支付的这一笔退款']);
72 71
                                     if ($pay_wx == 3){

+ 1 - 1
app/controller/api/store/service/Huafei.php

@@ -243,7 +243,7 @@ class Huafei extends BaseController
243 243
 		$request['order_no'] = $order_sn; 
244 244
 		$request['mobile'] = $phone;
245 245
 		$request['money'] = $money;
246
-		$request['recharge_type'] = 1;
246
+		$request['recharge_type'] = 0;
247 247
 		$request['notify_url'] = 'https://api.gdjbp.com/api/huafei/notify';
248 248
 		return $this->execute('/rest/Recharge/PushOrder', $request);
249 249
 	}