mirror of
https://github.com/itflow-org/itflow
synced 2026-11-22 20:37:24 +00:00
Add RMM alerts opening tickets: a provider's Edit picks which alerts open tickets (errors, errors and warnings, or every alert) and their ticket category, and the new RMM Alerts cron job looks every minute - a new alert on a device of a linked client opens a ticket on its client and asset with priority by severity, the same alert again goes on its open ticket and reopens it if resolved, and a cleared alert notes and resolves its ticket unless someone has written on it, it was moved to another status or another of its alerts is still open; the first look after turning alerts on, or the provider back on, takes open alerts as known, as does an alert raised before its device came into ITFlow; Tactical alerts read from PATCH /alerts/ and GET /alerts/id/ with no setup in Tactical; open alerts and their tickets on the asset's RMM card, an Alerts column on the providers list, the RMM ticket source on the ticket page and list, and the new-ticket address email; database 3.6.8 adds the alert columns to rmm_providers and the rmm_alerts table; 26.11.9 changelog entries
This commit is contained in:
34
db.sql
34
db.sql
@@ -2929,6 +2929,35 @@ CREATE TABLE `revenues` (
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
|
||||
--
|
||||
-- Table structure for table `rmm_alerts`
|
||||
--
|
||||
|
||||
DROP TABLE IF EXISTS `rmm_alerts`;
|
||||
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||
/*!40101 SET character_set_client = utf8mb4 */;
|
||||
CREATE TABLE `rmm_alerts` (
|
||||
`rmm_alert_id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`rmm_alert_provider_id` int(11) NOT NULL,
|
||||
`rmm_alert_remote_id` varchar(100) NOT NULL,
|
||||
`rmm_alert_device_id` int(11) NOT NULL DEFAULT 0,
|
||||
`rmm_alert_asset_id` int(11) NOT NULL DEFAULT 0,
|
||||
`rmm_alert_client_id` int(11) NOT NULL DEFAULT 0,
|
||||
`rmm_alert_about` varchar(150) NOT NULL DEFAULT '',
|
||||
`rmm_alert_type` varchar(20) NOT NULL DEFAULT '',
|
||||
`rmm_alert_severity` varchar(20) NOT NULL DEFAULT '',
|
||||
`rmm_alert_message` text DEFAULT NULL,
|
||||
`rmm_alert_raised_at` datetime DEFAULT NULL,
|
||||
`rmm_alert_cleared_at` datetime DEFAULT NULL,
|
||||
`rmm_alert_ticket_id` int(11) NOT NULL DEFAULT 0,
|
||||
`rmm_alert_created_at` datetime NOT NULL DEFAULT current_timestamp(),
|
||||
PRIMARY KEY (`rmm_alert_id`),
|
||||
UNIQUE KEY `rmm_alert_remote` (`rmm_alert_provider_id`,`rmm_alert_remote_id`),
|
||||
KEY `rmm_alert_device_id` (`rmm_alert_device_id`),
|
||||
KEY `rmm_alert_ticket_id` (`rmm_alert_ticket_id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||
|
||||
--
|
||||
-- Table structure for table `rmm_clients`
|
||||
--
|
||||
@@ -3016,6 +3045,11 @@ CREATE TABLE `rmm_providers` (
|
||||
`rmm_provider_sync_at` datetime DEFAULT NULL,
|
||||
`rmm_provider_sync_ok` tinyint(1) NOT NULL DEFAULT 0,
|
||||
`rmm_provider_sync_note` varchar(500) DEFAULT NULL,
|
||||
`rmm_provider_alert_level` varchar(20) NOT NULL DEFAULT '',
|
||||
`rmm_provider_alert_category_id` int(11) NOT NULL DEFAULT 0,
|
||||
`rmm_provider_alerts_since` datetime DEFAULT NULL,
|
||||
`rmm_provider_alerts_at` datetime DEFAULT NULL,
|
||||
`rmm_provider_alerts_note` varchar(500) DEFAULT NULL,
|
||||
`rmm_provider_created_at` datetime NOT NULL DEFAULT current_timestamp(),
|
||||
`rmm_provider_updated_at` datetime DEFAULT NULL ON UPDATE current_timestamp(),
|
||||
PRIMARY KEY (`rmm_provider_id`)
|
||||
|
||||
Reference in New Issue
Block a user