mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2024-05-11 05:55:19 +00:00
sms-forward: improve wording for single/multiple message(s)
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
|
||||
:global Identity;
|
||||
|
||||
:global IfThenElse;
|
||||
:global LogPrintExit;
|
||||
:global MailServerIsUp;
|
||||
:global ScriptLock;
|
||||
@@ -50,9 +51,10 @@ $WaitFullyConnected;
|
||||
}
|
||||
|
||||
:if ([ :len $Messages ] > 0) do={
|
||||
:local Count [ :len $Delete ];
|
||||
$SendNotification ([ $SymbolForNotification "incoming-envelope" ] . "SMS Forwarding from " . $Phone) \
|
||||
("These message(s) were received by " . $Identity . \
|
||||
" from " . $Phone . ":" . $Messages);
|
||||
("Received " . [ $IfThenElse ($Count = 1) "this message" ("these " . $Count . " messages") ] . \
|
||||
" by " . $Identity . " from " . $Phone . ":" . $Messages);
|
||||
:foreach Sms in=$Delete do={
|
||||
/ tool sms inbox remove $Sms;
|
||||
}
|
||||
|
Reference in New Issue
Block a user