mirror of
https://github.com/eworm-de/routeros-scripts
synced 2024-05-14 08:04:19 +00:00
mod/notification-matrix: introduce $PurgeMatrixQueue
... to purge the queue and remove the scheduler.
This commit is contained in:
parent
9a5d55da0d
commit
0aeb34e5e9
2 changed files with 14 additions and 0 deletions
|
@ -110,6 +110,11 @@ Place this before you call them:
|
|||
:global SendMatrix;
|
||||
:global SendNotification;
|
||||
|
||||
In case there is a situation when the queue needs to be purged there is a
|
||||
function available:
|
||||
|
||||
$PurgeMatrixQueue;
|
||||
|
||||
See also
|
||||
--------
|
||||
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
|
||||
:global FlushMatrixQueue;
|
||||
:global NotificationFunctions;
|
||||
:global PurgeMatrixQueue;
|
||||
:global SendMatrix;
|
||||
:global SendMatrix2;
|
||||
|
||||
|
@ -151,6 +152,14 @@
|
|||
}
|
||||
}
|
||||
|
||||
# purge the Matrix queue
|
||||
:set PurgeMatrixQueue do={
|
||||
:global MatrixQueue;
|
||||
|
||||
/system/scheduler/remove [ find where name="\$FlushMatrixQueue" ];
|
||||
:set MatrixQueue;
|
||||
}
|
||||
|
||||
# send notification via Matrix - expects at least two string arguments
|
||||
:set SendMatrix do={
|
||||
:global SendMatrix2;
|
||||
|
|
Loading…
Reference in a new issue