From 0b1b44af2779eac7469b58e1a319296f2e1cb7c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=9D=99?= Date: Tue, 12 Apr 2022 16:40:04 +0800 Subject: [PATCH] Update --- .../Callback/Http/Controllers/YeePayNotifyController.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/app/Endpoint/Callback/Http/Controllers/YeePayNotifyController.php b/app/Endpoint/Callback/Http/Controllers/YeePayNotifyController.php index a12e96e7..7275b514 100644 --- a/app/Endpoint/Callback/Http/Controllers/YeePayNotifyController.php +++ b/app/Endpoint/Callback/Http/Controllers/YeePayNotifyController.php @@ -3,9 +3,9 @@ namespace App\Endpoint\Callback\Http\Controllers; use App\Enums\WalletToBankLogStatus; -use App\Exceptions\BizException; use App\Models\WalletToBankLog; use App\Services\YeePayService; +use Exception; use Illuminate\Http\Request; use Illuminate\Support\Arr; use Illuminate\Support\Carbon; @@ -54,6 +54,10 @@ class YeePayNotifyController extends Controller return; } + if ($log->status !== WalletToBankLogStatus::Paying) { + return; + } + if ($orderStatus === 'SUCCESS') { $log->update([ 'status' => WalletToBankLogStatus::Success, @@ -85,6 +89,6 @@ class YeePayNotifyController extends Controller return; } - throw new BizException('签名错误'); + throw new Exception('签名错误'); } }