diff options
author | Simon Rettberg | 2023-08-02 16:50:08 +0200 |
---|---|---|
committer | Simon Rettberg | 2023-08-02 16:50:08 +0200 |
commit | eae4090944fb922d44899913b6d5cdaa97dc1041 (patch) | |
tree | 7bbb14fdbb3b5229e3b1c08d65b13f2c82435f35 /modules-available/statistics | |
parent | [minilinux] Only create new branch if it contains any versions (diff) | |
download | slx-admin-eae4090944fb922d44899913b6d5cdaa97dc1041.tar.gz slx-admin-eae4090944fb922d44899913b6d5cdaa97dc1041.tar.xz slx-admin-eae4090944fb922d44899913b6d5cdaa97dc1041.zip |
[statistics] Add button to copy existing rule
Diffstat (limited to 'modules-available/statistics')
-rw-r--r-- | modules-available/statistics/api.inc.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/modules-available/statistics/api.inc.php b/modules-available/statistics/api.inc.php index d6549392..6875193d 100644 --- a/modules-available/statistics/api.inc.php +++ b/modules-available/statistics/api.inc.php @@ -193,6 +193,11 @@ if ($type[0] === '~') { // Add anything not present in $new from $old $new += $old; $new['oldlastboot'] = $old['lastboot']; + } else { + // First boot, mock some important fields for event log filtering + $new['oldlastboot'] = 0; + $new['oldlastseen'] = 0; + $new['oldstate'] = 'OFFLINE'; } unset($new['data']); |