From df98653c2c9d096d9c1e158edd89c446cbb38d66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9Cwanyongkang=E2=80=9D?= <“937888580@qq.com”> Date: Mon, 12 May 2025 14:13:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=BB=AD=E8=B4=B9=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/api/controller/Account.php | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/app/api/controller/Account.php b/app/api/controller/Account.php index e7284e9..cbbf647 100644 --- a/app/api/controller/Account.php +++ b/app/api/controller/Account.php @@ -84,6 +84,29 @@ class Account $data = $_GET; $url = 'https://juip.com/product/ApiCreateOrder'; + if ($data['type'] == 3) { + if ((strpos($data['account'], ',') !== false || strpos($data['account'], '、') !== false || strpos($data['account'], ',') !== false)) { + $data = [ + 'Code' => 0, + 'Message' => '请续费单个账户', + ]; + echo json_encode($data); + die; + } + + $account_model = new ProductAccount; + $info = $account_model->getOne(['Account'=>$data['account'],"PackageId" => $data['package']],'ProductName,PackageName,Account,ConnectCount,StartTime,EndTime'); + + if ($data['connect'] != $info['ConnectCount']) { + $data = [ + 'Code' => 0, + 'Message' => '连接数不正确,请核对后重新请求', + ]; + echo json_encode($data); + die; + } + } + $params = array( "apikey" => $data['apikey'], "PackageId" => $data['package'],