From 755cf15794bd16e5e46edddc878726d0d5e4153f Mon Sep 17 00:00:00 2001 From: lingling <1077478963@qq.com> Date: Mon, 10 Mar 2025 21:06:24 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=9C=A8=20Task2=20=E7=B1=BB=E4=B8=AD?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E8=87=AA=E5=8A=A8=E5=88=A0=E9=99=A4=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E9=85=8D=E7=BD=AE=E6=9F=A5=E8=AF=A2=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- process/Task2.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/process/Task2.php b/process/Task2.php index 4437ff3..2c40273 100644 --- a/process/Task2.php +++ b/process/Task2.php @@ -6,6 +6,7 @@ use app\dao\UserPhoneLogDao; use App\Utils\API\SendCode; use app\model\UserPhone; use app\dao\UserRewardDao; +use app\model\Dictionary; use support\Log; use Workerman\Crontab\Crontab; use GuzzleHttp\Client; @@ -22,6 +23,8 @@ class Task2 new Crontab('0 */1 * * * *', function () { $start_time = time(); Rocketgo::test_login(); + //查询系统配置 是否自动删除用户 + $autodelete=Dictionary::where('key','autodelete')->first(); Log::info("查询任务开始"); // 获取账号列表 $res = Rocketgo::account_list(); @@ -44,7 +47,7 @@ class Task2 $updateData = []; foreach ($res as $v) { - if ($v['failedReason'] !== null) { + if ($v['failedReason'] !== null && $autodelete->value=='1') { SendCode::delWS($v['username']); continue; }