From 89acc07f7eee3063e58e348f542498c2f3ee124c Mon Sep 17 00:00:00 2001 From: Terry <2358269014@qq.com> Date: Tue, 15 Oct 2019 18:16:16 +0800 Subject: [PATCH] =?UTF-8?q?vue=20paypal=E6=94=AF=E4=BB=98=EF=BC=8Cincremen?= =?UTF-8?q?tId?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/appserver/modules/Payment/block/paypal/standard/Start.php | 4 ++-- .../modules/Payment/controllers/paypal/StandardController.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/appserver/modules/Payment/block/paypal/standard/Start.php b/app/appserver/modules/Payment/block/paypal/standard/Start.php index 338dec9b..2654aa86 100644 --- a/app/appserver/modules/Payment/block/paypal/standard/Start.php +++ b/app/appserver/modules/Payment/block/paypal/standard/Start.php @@ -17,7 +17,7 @@ use Yii; */ class Start { - public function startPayment() + public function startPayment($increment_id) { $methodName_ = 'SetExpressCheckout'; $return_url = Yii::$app->request->post('return_url'); @@ -29,7 +29,7 @@ class Start //var_dump($checkoutReturn); if (strtolower($checkoutReturn['ACK']) == 'success') { $token = $checkoutReturn['TOKEN']; - $increment_id = Yii::$service->order->getSessionIncrementId(); + //$increment_id = Yii::$service->order->getSessionIncrementId(); //echo $increment_id ;exit; # 将token写入到订单中 Yii::$service->order->updateTokenByIncrementId($increment_id,$token); diff --git a/app/appserver/modules/Payment/controllers/paypal/StandardController.php b/app/appserver/modules/Payment/controllers/paypal/StandardController.php index 817cfe42..f5265c1f 100644 --- a/app/appserver/modules/Payment/controllers/paypal/StandardController.php +++ b/app/appserver/modules/Payment/controllers/paypal/StandardController.php @@ -32,7 +32,7 @@ class StandardController extends AppserverController Yii::$service->payment->setPaymentMethod($payment_method); $increment_id = Yii::$app->request->post('increment_id'); Yii::$service->order->setCurrentOrderIncrementId($increment_id); - return $this->getBlock()->startPayment(); + return $this->getBlock()->startPayment($increment_id); } /** * 2.Review 浠巔aypal纭鍚庤繑鍥炵殑閮ㄥ垎 -- GitLab