From f563d159df2e02407139224a8434d20e36d54118 Mon Sep 17 00:00:00 2001 From: limu <610543851@qq.com> Date: Sat, 24 Feb 2024 19:54:56 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=BB=E8=BE=91=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controller/api/user/User.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controller/api/user/User.php b/app/controller/api/user/User.php index 05f203e..5afee1e 100644 --- a/app/controller/api/user/User.php +++ b/app/controller/api/user/User.php @@ -422,7 +422,7 @@ class User extends BaseController ->where('ctime', '<=', $end) ->count(); - if (!empty($count) && $count > 10) { + if (!empty($count) && $count >= 10) { return app('json')->fail('达到上限'); } //加100分 @@ -455,7 +455,7 @@ class User extends BaseController ->where('ctime', '<=', $end) ->count(); - if (!empty($count) && $count > 10) { + if (!empty($count) && $count >= 10) { return app('json')->fail('达到上限'); } } @@ -490,7 +490,7 @@ class User extends BaseController $query->where('type', $type); } - $list = $query->page((int)$this->request->param('page'), $this->request->param('limit'))->select()->toArray(); + $list = $query->order('id desc')->page((int)$this->request->param('page'), $this->request->param('limit'))->select()->toArray(); $user = userModel::getDB()->where('uid', $this->user->uid)->find();