From 884a1fc8f1ab218db5b6d43de69e6c5d5719044e Mon Sep 17 00:00:00 2001 From: tpingzhang <635929049@qq.com> Date: Wed, 13 Nov 2019 18:18:14 +0800 Subject: [PATCH] =?UTF-8?q?alipay=E6=97=A7=E7=89=88=20=20=E8=8B=A5?= =?UTF-8?q?=E6=98=AF=E5=8F=8C=E4=B9=BE=E6=94=AF=E4=BB=98=20=20=20=E5=88=99?= =?UTF-8?q?=E5=88=87=E5=9B=9Eapp=E6=94=AF=E4=BB=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Sdk/Controller/AppleController.class.php | 2 +- Application/Sdk/Controller/UserController.class.php | 3 +++ Application/Sdk/Controller/WapPayController.class.php | 6 +++--- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Application/Sdk/Controller/AppleController.class.php b/Application/Sdk/Controller/AppleController.class.php index d0566a97..5f9d0061 100644 --- a/Application/Sdk/Controller/AppleController.class.php +++ b/Application/Sdk/Controller/AppleController.class.php @@ -126,7 +126,7 @@ class AppleController extends BaseController{ // $this->other_price($request); - if(get_zfb_type()==0){ // 支付宝官方 + if(get_zfb_type()==0 || $request['api_ver'] != 2){ // 支付宝官方 if(C('alipay.way')==1/* || ($request['is_create_ordernumer']==1 && C('alipay.way')==0) */){ /* wap */ $game_set_data = get_game_set_info($request['game_id']); diff --git a/Application/Sdk/Controller/UserController.class.php b/Application/Sdk/Controller/UserController.class.php index a67f1617..a085bb2b 100644 --- a/Application/Sdk/Controller/UserController.class.php +++ b/Application/Sdk/Controller/UserController.class.php @@ -1902,6 +1902,9 @@ class UserController extends BaseController // pp($squnion_pay); //0:APP 1:WAP $zfb_type = pay_set_status('alipay') == 1 ? (empty(C('alipay.way')) ? 0 : C('alipay.way')) : 1; + if ($request['api_ver'] != 2) { + $zfb_type = 0; + } echo base64_encode(json_encode(array( 'status' => 200, 'wx_game' => $wx_game, diff --git a/Application/Sdk/Controller/WapPayController.class.php b/Application/Sdk/Controller/WapPayController.class.php index 4a305d31..80fb43d5 100644 --- a/Application/Sdk/Controller/WapPayController.class.php +++ b/Application/Sdk/Controller/WapPayController.class.php @@ -91,7 +91,7 @@ class WapPayController extends BaseController{ $prefix = $request['code'] == 1 ? "SP_" : "PF_"; $out_trade_no = $prefix.date('Ymd').date('His').sp_random_string(4); - $request = $this->other_price($request); +// $request = $this->other_price($request); //Log::write(serialize($request), Log::DEBUG); if(get_zfb_type()==0){ @@ -677,8 +677,8 @@ class WapPayController extends BaseController{ file_put_contents("./Application/Sdk/Scheme/".$request['game_id'].".txt",$request['scheme']); } // 绑币平台币优先处理 - $this->other_price($request, $discountAmount); - $pay_amount = $request['price']; +// $this->other_price($request, $discountAmount); +// $pay_amount = $request['price']; $game_set_data = get_game_set_info($request['game_id']); //$request['game_name']