From 7d7c9571ce40d3234878302e6d53fe8b82590344 Mon Sep 17 00:00:00 2001 From: elf <360197197@qq.com> Date: Mon, 25 Dec 2023 22:08:18 +0800 Subject: [PATCH] yh --- app/Controller/Payment/AccountController.php | 4 ++-- public/account.html | 6 +++--- public/login.html | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/Controller/Payment/AccountController.php b/app/Controller/Payment/AccountController.php index 059bec4..5b2bbf9 100644 --- a/app/Controller/Payment/AccountController.php +++ b/app/Controller/Payment/AccountController.php @@ -245,7 +245,7 @@ class AccountController extends AbstractController $query->where('last_card_no', $request->input('bankCardNo')); } if (!empty($request->input('cardUserName'))) { - $query->where('card_user_name', 'like', Db::raw('%' . $request->input('cardUserName'))); + $query->where('card_user_name', 'like', '%' . $request->input('cardUserName')); } $status = $request->input('status'); if (!empty($status)) { @@ -296,7 +296,7 @@ class AccountController extends AbstractController } $records[] = [ 'out_order_no' => $order->out_order_no, - 'created_at' => $order->created_at, + 'created_at' => $order->created_at->format('Y-m-d H:i:s'), 'status' => $order->status, 'amount' => number_format($order->amount / 100, 2, '.', ''), 'card_user_name' => $order->card_user_name, diff --git a/public/account.html b/public/account.html index 0730419..eb770df 100644 --- a/public/account.html +++ b/public/account.html @@ -142,7 +142,7 @@ }, created() { if (!window.sessionStorage.getItem('token')) { - // window.location.href = '/login.html' + window.location.href = '/login.html' return; } else { this.getUserInfo(); @@ -160,8 +160,8 @@ let result = response.data if (result.code != 1000) { this.$message.error(response.data.message); - // window.sessionStorage.removeItem('token'); - // window.location.href = '/login.html'; + window.sessionStorage.removeItem('token'); + window.location.href = '/login.html'; return; } this.username = result.data.username; diff --git a/public/login.html b/public/login.html index c5bd5e4..bf3ff3f 100644 --- a/public/login.html +++ b/public/login.html @@ -107,7 +107,7 @@ return this.$message.error(response.data.message); } window.sessionStorage.setItem('token', result.data.token) - // window.location.href = '/account.html'; + window.location.href = '/account.html'; }) .catch((error) => { this.$message.error('请求错误');