Skip to content

Commit

Permalink
🔌Plugins page rebuild with DataTables
Browse files Browse the repository at this point in the history
  • Loading branch information
jokob-sk committed Oct 24, 2024
1 parent 907a3e1 commit 4c46b27
Show file tree
Hide file tree
Showing 38 changed files with 1,303 additions and 603 deletions.
6 changes: 3 additions & 3 deletions docs/NOTIFICATIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ There are 4 ways how to influence notifications:

There are 4 settings on the device for influencing notifications. You can:

1. Completely disable the scanning of the device
2. **Alert all events**, connections, disconnections, IP changes (noisy, usually not recommended)
3. **Alert down** - alerts when a device goes down. This setting overrides disabled Alert All Events, so you will get a notification of a device going down even if you don't have Alert All Events ticked.
1. **Scan device** - Completely disable the scanning of the device
2. **Alert all events** - Enables extensive alerts of connections, disconnections, IP changes (noisy, usually not recommended)
3. **Alert down** - Alerts when a device goes down. This setting overrides disabled Alert All Events, so you will get a notification of a device going down even if you don't have **Alert All Events** ticked.
4. **Skip repeated notifications**, if for example you know there is a temporary issue and want to pause the same notification for this device for a given time.

## Plugin settings 🔌
Expand Down
31 changes: 29 additions & 2 deletions front/css/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -1208,7 +1208,7 @@ input[readonly] {
background-color:#606060 !important;
}

.networkPageHelp{
.helpIconSmallTopRight{
position: absolute;
font-size: x-small;
margin-bottom: 6px;
Expand Down Expand Up @@ -1407,7 +1407,7 @@ input[readonly] {
.plugin-content #tabs-content-location
{
margin: 0px;

padding-top: 0;
}

.plugins-description
Expand Down Expand Up @@ -1462,6 +1462,33 @@ input[readonly] {
}


.textOverflow
{
white-space: nowrap; /* Prevent text from wrapping to a new line */
overflow: hidden; /* Hide the overflowed text */
text-overflow: ellipsis; /* Show ellipsis (...) */
}

.table-stretched
{
min-width: -moz-available;
min-width: -webkit-fill-available;
}

.pluginBadge
{
float: right;
}

.pluginBadgeWrap
{
float: right;
display: ruby;
z-index: 1;
position: sticky;
margin-top: 1px;
}

/* -----------------------------------------------------------------------------
Spin
----------------------------------------------------------------------------- */
Expand Down
8 changes: 5 additions & 3 deletions front/deviceDetails.php
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@
</div>

<!-- Network -->
<h4 class="bottom-border-aqua"><?= lang('DevDetail_MainInfo_Network_Title');?><span class="networkPageHelp"> <a target="_blank" href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/NETWORK_TREE.md"><i class="fa fa-circle-question"></i></a><span></h4>
<h4 class="bottom-border-aqua"><?= lang('DevDetail_MainInfo_Network_Title');?><span class="helpIconSmallTopRight"> <a target="_blank" href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/NETWORK_TREE.md"><i class="fa fa-circle-question"></i></a><span></h4>
<div class="form-group" title="<?= lang('DevDetail_Network_Node_hover');?>">
<label class="col-sm-3 control-label"><?= lang('DevDetail_MainInfo_Network');?></label>
<div class="col-sm-9">
Expand Down Expand Up @@ -370,7 +370,8 @@

<!-- column 3 -->
<div class="col-lg-4 col-sm-6 col-xs-12">
<h4 class="bottom-border-aqua"><?= lang('DevDetail_EveandAl_Title');?></h4>
<h4 class="bottom-border-aqua"><?= lang('DevDetail_EveandAl_Title');?>
<span class="helpIconSmallTopRight"> <a target="_blank" href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/NOTIFICATIONS.md"><i class="fa fa-circle-question"></i></a><span></h4>
<div class="box-body form-horizontal">

<!-- Scan Cycle -->
Expand Down Expand Up @@ -455,7 +456,8 @@
<i style="font-size: 24px;" class="text-yellow glyphicon glyphicon-random"></i> &nbsp &nbsp </span>

<a href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/RANDOM_MAC.md" target="_blank" style="color: #777;">
<i class="fa fa-info-circle"></i> </a>
<i class="fa fa-info-circle"></i>
</a>
</div>
</div>
</div>
Expand Down
2 changes: 2 additions & 0 deletions front/devices.php
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,8 @@
// -----------------------------------------------------------------------------
function main () {

showSpinner();

//initialize the table headers in the correct order
var availableColumns = getSettingOptions("UI_device_columns").split(",");
var headersDefaultOrder = availableColumns.map(val => getString(val));
Expand Down
2 changes: 1 addition & 1 deletion front/network.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<?php require 'php/templates/notification.php'; ?>
<h1 id="pageTitle">
<i class="fa fa-network-wired"></i> <?= lang('Network_Title');?>
<span class="networkPageHelp"> <a target="_blank" href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/NETWORK_TREE.md"><i class="fa fa-circle-question"></i></a><span>
<span class="helpIconSmallTopRight"> <a target="_blank" href="https://github.com/jokob-sk/NetAlertX/blob/main/docs/NETWORK_TREE.md"><i class="fa fa-circle-question"></i></a><span>
</h1>
</section>

Expand Down
Empty file modified front/php/templates/language/fr_fr.json
100644 → 100755
Empty file.
15 changes: 15 additions & 0 deletions front/plugins/__template/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,21 @@
}
],
"database_column_definitions": [
{
"column": "Index",
"css_classes": "col-sm-2",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "Index"
}
]
},
{
"column": "Object_PrimaryID",
"mapped_to_column": "cur_MAC",
Expand Down
14 changes: 5 additions & 9 deletions front/plugins/_publisher_apprise/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down Expand Up @@ -104,7 +100,7 @@
},
{
"column": "DateTimeCreated",
"css_classes": "col-sm-2",
"css_classes": "col-sm-3",
"show": true,
"type": "label",
"default_value": "",
Expand Down Expand Up @@ -145,7 +141,7 @@
"options": [
{
"type": "eval",
"param": "`<a href='/report.php?guid=${value}'>${value}</a>`"
"param": "`<a href='/report.php?guid=${value}'>Link</a>`"
}
],
"localized": ["name"],
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_email/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_mqtt/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_ntfy/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_pushover/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_pushsafer/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_telegram/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
10 changes: 3 additions & 7 deletions front/plugins/_publisher_webhook/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,19 +33,15 @@
{
"column": "Index",
"css_classes": "col-sm-2",
"show": false,
"type": "label",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "N/A"
},
{
"language_code": "es_es",
"string": "N/A"
"string": "Index"
}
]
},
Expand Down
15 changes: 15 additions & 0 deletions front/plugins/arp_scan/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,21 @@
}
],
"database_column_definitions": [
{
"column": "Index",
"css_classes": "col-sm-2",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "Index"
}
]
},
{
"column": "Object_PrimaryID",
"mapped_to_column": "cur_MAC",
Expand Down
15 changes: 15 additions & 0 deletions front/plugins/avahi_scan/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,21 @@
}
],
"database_column_definitions": [
{
"column": "Index",
"css_classes": "col-sm-2",
"show": true,
"type": "none",
"default_value": "",
"options": [],
"localized": ["name"],
"name": [
{
"language_code": "en_us",
"string": "Index"
}
]
},
{
"column": "Object_PrimaryID",
"css_classes": "col-sm-2",
Expand Down
Loading

0 comments on commit 4c46b27

Please sign in to comment.