mirror of
https://git.eworm.de/cgit/routeros-scripts
synced 2025-08-02 17:24:30 +02:00
sms-forward: improve wording for single/multiple message(s)
This commit is contained in:
parent
4a85deb45c
commit
4af1f5dec2
1 changed files with 4 additions and 2 deletions
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue