Working on device status and alerts.

This commit is contained in:
Scott Idem
2024-10-17 18:26:56 -04:00
parent 67b01c5884
commit 172763bc26
7 changed files with 241 additions and 107 deletions

View File

@@ -297,6 +297,7 @@ export async function update_ae_obj__event_device(
}
// Not yet used or tested fully!
// Updated 2024-10-16
export async function search__event_device(
{
@@ -475,10 +476,13 @@ export function db_save_ae_obj_li__event_device(
alert: obj.alert,
alert_msg: obj.alert_msg,
alert_on: obj.alert_on,
status: obj.status,
status_msg: obj.status_msg,
status_on: obj.status_on,
record_status: obj.record_status,
record_status_msg: obj.record_status_msg,
record_status_on: obj.record_status_on,
info_hostname: obj.info_hostname,
info_ip_list: obj.info_ip_list,

View File

@@ -2,6 +2,7 @@
// Import all the functions from this library:
import * as events from "$lib/ae_events__event";
import * as events_device from "$lib/ae_events__event_device";
import {
load_ae_obj_id__event_file,
@@ -80,6 +81,12 @@ let export_obj = {
db_save_ae_obj_li__event: events.db_save_ae_obj_li__event,
sync_config__event_pres_mgmt: events.sync_config__event_pres_mgmt,
load_ae_obj_id__event_device: events_device.load_ae_obj_id__event_device,
load_ae_obj_li__event_device: events_device.load_ae_obj_li__event_device,
create_ae_obj__event_device: events_device.create_ae_obj__event_device,
update_ae_obj__event_device: events_device.update_ae_obj__event_device,
db_save_ae_obj_li__event_device: events_device.db_save_ae_obj_li__event_device,
load_ae_obj_id__event_file: load_ae_obj_id__event_file,
load_ae_obj_li__event_file: load_ae_obj_li__event_file,
delete_ae_obj_id__event_file: delete_ae_obj_id__event_file,

View File

@@ -167,10 +167,13 @@ export interface Device {
alert?: null|boolean;
alert_msg?: null|string;
alert_on?: null|string;
status?: null|string;
status_msg?: null|string;
status_on?: null|Date;
record_status?: null|string;
record_status_msg?: null|string;
record_status_on?: null|Date;
info_hostname?: null|string;
info_ip_list?: null|string; // Semi-colon separated list of IP addresses