no message

This commit is contained in:
hellcat 2025-04-18 20:59:51 +08:00
parent 308c5c253f
commit 7932a9a32c
3 changed files with 10 additions and 3 deletions

View File

@ -62,7 +62,7 @@ class TestsController
//test
// $s = "\/AticleSet__1115zz__sale_rate 1118.118";
// $s = "\/git#LastTime 1";
$s= "/cron#pause 4";
$s= "/option#list";
$oHttp = new Http();
$oHttp->sMethod = "post";

View File

@ -21,7 +21,7 @@ class Cmd extends Base {
'文章clone' => "article#clone id",
'git手动重置' => "git#pullR",
'文章find' => "article#find id",
'cron暂停' => "cron#pause 1",
'cron暂停' => "option#pause 1",
];
$this->oTGHttp->sendToTG(json_encode($aCmdList, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT));

View File

@ -3,7 +3,7 @@
namespace App\Services\TG\Hook\Mod;
use App\Models\Option as ModelOption;
class Cron extends Base {
class Option extends Base {
public function Pause($aParam)
{
@ -24,4 +24,11 @@ class Cron extends Base {
return json_encode(['error' => 'Option not found']);
}
public function List()
{
$aOptionList = ModelOption::all()->toArray();
return json_encode($aOptionList, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT);
}
}