Fix jwt-token
This commit is contained in:
@@ -503,14 +503,6 @@ module.exports = {
|
||||
type: Sequelize.TEXT,
|
||||
allowNull: true
|
||||
},
|
||||
conditions: {
|
||||
type: Sequelize.JSON,
|
||||
allowNull: false
|
||||
},
|
||||
actions: {
|
||||
type: Sequelize.JSON,
|
||||
allowNull: false
|
||||
},
|
||||
device_ids: {
|
||||
type: Sequelize.JSON,
|
||||
allowNull: true,
|
||||
|
||||
@@ -202,6 +202,17 @@ const setupDatabase = async () => {
|
||||
tenant_id: defaultTenant.id,
|
||||
name: 'Critical Security Threat',
|
||||
description: 'Immediate alert for critical and high threats to government facilities',
|
||||
conditions: {
|
||||
min_rssi: -55,
|
||||
drone_types: [0, 1, 2],
|
||||
time_window: 300,
|
||||
min_detections: 1
|
||||
},
|
||||
actions: {
|
||||
alert_channels: ['sms', 'email'],
|
||||
sms_phone_number: '+46701234567',
|
||||
priority: 'high'
|
||||
},
|
||||
is_active: true,
|
||||
device_ids: [],
|
||||
drone_types: [0, 1, 2],
|
||||
@@ -224,6 +235,7 @@ const setupDatabase = async () => {
|
||||
tenant_id: defaultTenant.id,
|
||||
name: 'Medium Threat Monitoring',
|
||||
description: 'Monitor medium threat drones in facility vicinity',
|
||||
|
||||
is_active: true,
|
||||
device_ids: ['device-alpha-001', 'device-beta-002'],
|
||||
drone_types: [1, 2],
|
||||
@@ -246,6 +258,16 @@ const setupDatabase = async () => {
|
||||
tenant_id: defaultTenant.id,
|
||||
name: 'Device Offline Alert',
|
||||
description: 'Alert when security devices go offline',
|
||||
conditions: {
|
||||
device_ids: ['device-alpha-001', 'device-beta-002', 'device-gamma-003'],
|
||||
time_window: 300,
|
||||
min_detections: 1
|
||||
},
|
||||
actions: {
|
||||
alert_channels: ['sms'],
|
||||
sms_phone_number: '+46701234567',
|
||||
priority: 'medium'
|
||||
},
|
||||
is_active: true,
|
||||
device_ids: ['device-alpha-001', 'device-beta-002', 'device-gamma-003'],
|
||||
drone_types: null,
|
||||
|
||||
Reference in New Issue
Block a user