mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-07 09:36:05 -08:00
Completing the graph extension
Known issues: - some small translations are not yet completed in gaph extension - some small translations are not yet completed in entire frontend Modification within the fork: - enforce only one scancycle (crontab and frontend) - if not already done, then sqlite3 must be installed - DB must be patched via install/pialert_patch_DB.sh, otherwise the scan will run into an error
This commit is contained in:
@@ -3,6 +3,7 @@ $Pia_Graph_Device_Time = array();
|
||||
$Pia_Graph_Device_All = array();
|
||||
$Pia_Graph_Device_Online = array();
|
||||
$Pia_Graph_Device_Down = array();
|
||||
$Pia_Graph_Device_Arch = array();
|
||||
$db = new SQLite3('../db/pialert.db');
|
||||
$results = $db->query('SELECT * FROM Online_History ORDER BY Scan_Date DESC LIMIT 144');
|
||||
while ($row = $results->fetchArray()) {
|
||||
@@ -12,6 +13,7 @@ while ($row = $results->fetchArray()) {
|
||||
array_push($Pia_Graph_Device_Down, $row['Down_Devices']);
|
||||
array_push($Pia_Graph_Device_All, $row['All_Devices']);
|
||||
array_push($Pia_Graph_Device_Online, $row['Online_Devices']);
|
||||
array_push($Pia_Graph_Device_Arch, $row['Archived_Devices']);
|
||||
}
|
||||
function pia_graph_devices_data($Pia_Graph_Array) {
|
||||
$Pia_Graph_Array_rev = array_reverse($Pia_Graph_Array);
|
||||
|
||||
Reference in New Issue
Block a user