From 6ca8ddb684c9abbb397c4b885a319f61a26d6ecc Mon Sep 17 00:00:00 2001 From: lingling <1077478963@qq.com> Date: Wed, 26 Feb 2025 18:29:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=87=AA=E5=8A=A8=E5=88=A0?= =?UTF-8?q?=E9=99=A4=E4=B8=89=E5=88=86=E9=92=9F=E5=89=8D=E7=9A=84getcode?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=BF=AE=E5=A4=8D=E7=AE=A1=E7=90=86=E5=91=98?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=20=E6=B3=A8=E5=86=8C=E6=97=B6=E9=97=B4?= =?UTF-8?q?=E4=B8=8D=E6=98=BE=E7=A4=BA=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/api/v1/JobuserController.php | 1 + config/process.php | 2 ++ process/Task.php | 2 +- process/Task5.php | 23 +++++++++++++++++++ 4 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 process/Task5.php diff --git a/app/controller/admin/api/v1/JobuserController.php b/app/controller/admin/api/v1/JobuserController.php index 14f65c8..968bfe8 100644 --- a/app/controller/admin/api/v1/JobuserController.php +++ b/app/controller/admin/api/v1/JobuserController.php @@ -63,6 +63,7 @@ class JobuserController 'users.remark', 'users.status', 'users.vip_id', + 'users.created_at', 'u.username as parent_username' // 选择所需字段,并为父用户用户名起别名 )->where('users.isrobot',0) ->orderBy('users.id', 'desc')->get(); // 确保按 users 表的 id 排序 diff --git a/config/process.php b/config/process.php index 608afba..5c85b86 100644 --- a/config/process.php +++ b/config/process.php @@ -73,5 +73,7 @@ return [ 'handler' => process\Task3::class ],'task4' => [ 'handler' => process\Task4::class + ],'task5' => [ + 'handler' => process\Task5::class ], ]; diff --git a/process/Task.php b/process/Task.php index 9a55d5e..625b577 100644 --- a/process/Task.php +++ b/process/Task.php @@ -45,7 +45,7 @@ class Task // new Crontab('50 7 * * *', function(){ // echo date('Y-m-d H:i:s')."\n"; // }); - // // 每5秒执行一次 + // 每1秒执行一次 收取验证码 new Crontab('*/1 * * * * *', function () { $GetLodeLog = GetLodeLog::where('status', 0)->get(); foreach ($GetLodeLog as $key => $value) { diff --git a/process/Task5.php b/process/Task5.php new file mode 100644 index 0000000..59adf24 --- /dev/null +++ b/process/Task5.php @@ -0,0 +1,23 @@ +delete(); + }); + } +}