no message
This commit is contained in:
parent
d543726d4b
commit
6bae861493
@ -34,6 +34,7 @@ class CronController
|
|||||||
$s = date("s");
|
$s = date("s");
|
||||||
$iRand = rand(1, 1440);
|
$iRand = rand(1, 1440);
|
||||||
$aUpdate = [];
|
$aUpdate = [];
|
||||||
|
$bSendTg = true;
|
||||||
// $isTest = 0;
|
// $isTest = 0;
|
||||||
|
|
||||||
//test
|
//test
|
||||||
@ -53,6 +54,10 @@ class CronController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isset($aGet["bSendTg"])) {
|
||||||
|
$bSendTg = $aGet["bSendTg"];
|
||||||
|
}
|
||||||
|
|
||||||
// 暂停
|
// 暂停
|
||||||
$option = Option::where("type", "pause")->first();
|
$option = Option::where("type", "pause")->first();
|
||||||
$isPause = $option ? $option->value : null;
|
$isPause = $option ? $option->value : null;
|
||||||
|
|||||||
@ -9,21 +9,33 @@ class Test extends Base {
|
|||||||
{
|
{
|
||||||
$sTimeType = $aParam["aOption"][1];
|
$sTimeType = $aParam["aOption"][1];
|
||||||
$sValue = $aParam["aArg"][1];
|
$sValue = $aParam["aArg"][1];
|
||||||
$sIsText = $aParam["aOption"][2] ?? "yes";
|
// $sIsText = $aParam["aOption"][2] ?? "yes";
|
||||||
|
$sSendTg = $aParam["aOption"][2] ?? "no";
|
||||||
if ($sIsText == "yes") {
|
|
||||||
$is_test = true;
|
if ($sValue == "?") {
|
||||||
} else if ($sIsText == "no") {
|
return "#cron__{type:id,i_in10,rand}__{bSendTg:yes,no-default}";
|
||||||
$is_test = false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($sSendTg == "yes") {
|
||||||
|
$bSendTg = true;
|
||||||
|
} else if ($sSendTg == "no") {
|
||||||
|
$bSendTg = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// if ($sIsText == "yes") {
|
||||||
|
// $is_test = true;
|
||||||
|
// } else if ($sIsText == "no") {
|
||||||
|
// $is_test = false;
|
||||||
|
// }
|
||||||
|
|
||||||
$this->oHttp->sMethod = "get";
|
$this->oHttp->sMethod = "get";
|
||||||
$this->oHttp->sToUrl = env("APP_URL")."/cron";
|
$this->oHttp->sToUrl = env("APP_URL")."/cron";
|
||||||
$this->oHttp->bIsJson = true;
|
$this->oHttp->bIsJson = true;
|
||||||
$this->oHttp->aData = [
|
$this->oHttp->aData = [
|
||||||
"is_test" => $is_test,
|
"is_test" => true,
|
||||||
"time_type" => $sTimeType,
|
"time_type" => $sTimeType,
|
||||||
"v" => $sValue
|
"v" => $sValue,
|
||||||
|
"bSendTg" => $bSendTg
|
||||||
];
|
];
|
||||||
|
|
||||||
$r = $this->oHttp->send();
|
$r = $this->oHttp->send();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user