no message

This commit is contained in:
hellcat 2025-04-03 19:50:21 +08:00
parent 219cfb009b
commit d9089690e9
4 changed files with 20 additions and 2 deletions

View File

@ -35,7 +35,7 @@ $oHttp->aData = [
'type' => 'private'
],
'date' => 1610000000,
"text" => "\/duckFind jp03",
"text" => "\/reportWidth",
]
];

View File

@ -60,6 +60,7 @@ EOL;
$jobs->reportBandWidth();
$jobs->resetFreeUserBandwidth();
$jobs->sendDailyTrafficReport();
$jobs->clearTodayWidth();
// 每日清除前一天残留TgStep
$jobs->clearTgStep();

View File

@ -103,6 +103,18 @@ final class HookController
http_response_code(200);exit;
}
// 流量报告
// /reportWidth
if (strpos($sText, '/reportWidth') === 0 || strpos($sText, '\/reportWidth') === 0) {
$jobs = new \App\Services\Cron();
$jobs->reportBandWidth();
Http::response(200, 'ok');
}
// 查找用户
if (strpos($sText, '/userFind') === 0 || strpos($sText, '\/userFind') === 0) {

View File

@ -671,7 +671,6 @@ final class Cron
// var_dump($sTgReport);
(new Telegram())->send(0, $sTgReport);
Zhuanfas::query()->update(['today_width' => 0]);
// 流量报告,机器
$oTgSendFormat = new TgSendFormat();
@ -710,7 +709,13 @@ final class Cron
// var_dump($sTgReport);
(new Telegram())->send(0, $sTgReport);
}
public static function clearTodayWidth(): void
{
Ducks::query()->update(['today_width' => 0]);
Zhuanfas::query()->update(['today_width' => 0]);
}
public static function reportBandWidth_back(): void