From 55a95a9e67699189f8a630608ea5ba2719cd9d89 Mon Sep 17 00:00:00 2001 From: ljl Date: Sun, 28 Apr 2024 19:16:46 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Base/Tool/Log.class.php | 11 +++++++++++ .../Sdk/Controller/ExchangeController.class.php | 7 +++++-- Application/Sdk/Controller/SpendController.class.php | 8 ++++++++ 3 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 Application/Base/Tool/Log.class.php diff --git a/Application/Base/Tool/Log.class.php b/Application/Base/Tool/Log.class.php new file mode 100644 index 0000000..9397ee0 --- /dev/null +++ b/Application/Base/Tool/Log.class.php @@ -0,0 +1,11 @@ += 2) { $payPage = "pay_way"; // 用户 diff --git a/Application/Sdk/Controller/SpendController.class.php b/Application/Sdk/Controller/SpendController.class.php index 611700a..af12c86 100644 --- a/Application/Sdk/Controller/SpendController.class.php +++ b/Application/Sdk/Controller/SpendController.class.php @@ -2,6 +2,7 @@ namespace Sdk\Controller; +use Base\Tool\Log as ToolLog; use Think\Controller; use Org\JtpaySDK\Jtpay; use Org\SqpaySDK\Sqpay; @@ -56,11 +57,18 @@ class SpendController extends Controller { echo "access deny!"; die(); } + + ToolLog::write('user_token: ' . $user_token, Log::INFO, 'payment'); + ToolLog::write('user_id: ' . $user_id, Log::INFO, 'payment'); + ToolLog::write('game_id: ' . $game_id, Log::INFO, 'payment'); + $userId = M('user_token', 'tab_')->where([ 'user_token'=>$user_token, 'user_id' => $user_id, 'game_id' => $game_id ])->getField('id'); + ToolLog::write('sql: ' . M('ususer_tokener','tab_')->getLastSql(), 'payment'); + ToolLog::write('userId: ' . $userId, Log::INFO, 'payment'); if (!$userId) { echo $user_token."请重新登入!".$user_id.$game_id; die();