mirror of
https://github.com/laspavel/mikrotik-scripts.git
synced 2025-06-21 05:45:44 +02:00
Add UTF8 text messages
This commit is contained in:
parent
20a28a9849
commit
81763af7ac
2 changed files with 12 additions and 6 deletions
|
@ -1,10 +1,10 @@
|
|||
# https://www.urlencoder.org/
|
||||
:do {
|
||||
:local DeviceName [/system identity get name];
|
||||
:local versioninfo [/system package update check-for-updates as-value]
|
||||
:if (($versioninfo->"installed-version") != ($versioninfo->"latest-version")) do={
|
||||
/log info ("Found new firmware version " . ($versioninfo->"latest-version") . " installing now!")
|
||||
|
||||
:local MessageText ("<b>AutoUpdate $DeviceName:</b> Found new firmware version ". ($versioninfo->"latest-version") . ". Installing now!");
|
||||
/log info ("Installing new firmware version on $DeviceName: ". ($versioninfo->"latest-version"))
|
||||
:local MessageText ("*AutoUpdate%20$DeviceName%3A*%20Found%20new%20firmware%20version%20". ($versioninfo->"latest-version")."%20Installing%20now%21");
|
||||
:local SendTelegramMessage [:parse [/system script get SendTelegram source]];
|
||||
$SendTelegramMessage MessageText=$MessageText;
|
||||
|
||||
|
|
|
@ -1,8 +1,14 @@
|
|||
:global RebootStatus;
|
||||
:if ($RebootStatus != true) do={
|
||||
# https://www.urlencoder.org/
|
||||
:global ReBootStatus;
|
||||
:local DeviceName [/system identity get name];
|
||||
:local MessageText ("*RebootStatus%20$DeviceName*%3A%20I%20REBOOT%20NOW%20%21%21%21");
|
||||
:local SendTelegramMessage [:parse [/system script get SendTelegram source]];
|
||||
$SendTelegramMessage MessageText=$MessageText;
|
||||
:set ReBootStatus true;
|
||||
:if ($ReBootStatus != true) do={
|
||||
:local DeviceName [/system identity get name];
|
||||
:local MessageText ("<b>RebootStatus $DeviceName:</b> I reboot now!");
|
||||
:local SendTelegramMessage [:parse [/system script get SendTelegram source]];
|
||||
$SendTelegramMessage MessageText=$MessageText;
|
||||
:set RebootStatus true;
|
||||
:set ReBootStatus true;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue