From 4b5e8bb7632d5e20ef9fea6ec64159b4dbe6ff26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=8A=80=E6=9C=AF=E8=80=81=E8=83=A1?= <1094551889@qq.com> Date: Mon, 11 Nov 2024 15:58:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=B8=80=E4=BA=9B=E5=B0=8F?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controller/IndexController.php | 6 ++---- app/controller/PayController.php | 6 +++--- app/controller/PayManageController.php | 2 ++ app/controller/api/PluginController.php | 2 -- extend/MpayClass.php | 2 ++ public/test.php | 15 +++++++++++++-- view/pay_manage/index.html | 2 +- 7 files changed, 23 insertions(+), 12 deletions(-) diff --git a/app/controller/IndexController.php b/app/controller/IndexController.php index ee4c2b6..d449a03 100644 --- a/app/controller/IndexController.php +++ b/app/controller/IndexController.php @@ -21,9 +21,7 @@ class IndexController } public function test() { - $pay = new \payclient\PayClass(['username'=>1531,'password'=>15646]); - - - return '123'; + $web = \request()->domain(); + return $web; } } diff --git a/app/controller/PayController.php b/app/controller/PayController.php index 40e31c8..a09e3d9 100644 --- a/app/controller/PayController.php +++ b/app/controller/PayController.php @@ -195,11 +195,11 @@ class PayController foreach ($new_orders as $new_order) { foreach ($activeOrders as $order) { // 支付方式核对 - $is_payway = $order->type === $new_order['payway']; + $is_payway = $order->type == $new_order['payway']; // 支付渠道核对 - $is_channel = $cids[$order->cid] === $new_order['channel']; + $is_channel = $cids[$order->cid] == $new_order['channel']; // 金额核对 - $is_money = $order->money === $new_order['price']; + $is_money = $order->money == $new_order['price']; // 订单核对 if ($is_payway && $is_channel && $is_money) { $res = $this->updateOrderState($order, $new_order['order_no']); diff --git a/app/controller/PayManageController.php b/app/controller/PayManageController.php index cce43a1..637adc2 100644 --- a/app/controller/PayManageController.php +++ b/app/controller/PayManageController.php @@ -13,6 +13,8 @@ class PayManageController extends BaseController { public function index() { + $domain = $this->request->domain(); + View::assign('domain', $domain); return View::fetch(); } // 编辑账号 diff --git a/app/controller/api/PluginController.php b/app/controller/api/PluginController.php index 2eecc79..6563622 100644 --- a/app/controller/api/PluginController.php +++ b/app/controller/api/PluginController.php @@ -5,8 +5,6 @@ declare(strict_types=1); namespace app\controller\api; use app\BaseController; -use app\model\Platform; -use think\facade\View; class PluginController extends BaseController { diff --git a/extend/MpayClass.php b/extend/MpayClass.php index a7bcf6e..dce8252 100644 --- a/extend/MpayClass.php +++ b/extend/MpayClass.php @@ -1,5 +1,7 @@ {{# return window.location.origin + '/checkPayResult?pid='+d.pid+'&aid='+d.id }}` }, + { title: '监听地址', field: 'payurl', align: 'center', templet: `