feat: 初始化项目基础架构和核心功能
- 添加项目基础结构:Cargo.toml、.gitignore、设备UID和密钥文件 - 实现前端Vue3项目结构:路由、登录页面、设备管理页面 - 添加核心协议定义(crates/protocol):设备状态、资产、USB事件等 - 实现客户端监控模块:系统状态收集、资产收集 - 实现服务端基础API和插件系统 - 添加数据库迁移脚本:设备管理、资产跟踪、告警系统等 - 实现前端设备状态展示和基本交互 - 添加使用时长统计和水印功能插件
This commit is contained in:
23
migrations/008_plugins_popup_blocker.sql
Normal file
23
migrations/008_plugins_popup_blocker.sql
Normal file
@@ -0,0 +1,23 @@
|
||||
-- 008_plugins_popup_blocker.sql: Popup Blocker plugin (弹窗拦截)
|
||||
|
||||
CREATE TABLE IF NOT EXISTS popup_filter_rules (
|
||||
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
||||
rule_type TEXT NOT NULL CHECK(rule_type IN ('block', 'allow')),
|
||||
window_title TEXT,
|
||||
window_class TEXT,
|
||||
process_name TEXT,
|
||||
target_type TEXT NOT NULL DEFAULT 'global' CHECK(target_type IN ('global', 'group', 'device')),
|
||||
target_id TEXT,
|
||||
enabled INTEGER NOT NULL DEFAULT 1,
|
||||
created_at TEXT NOT NULL DEFAULT (datetime('now'))
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS popup_block_stats (
|
||||
id INTEGER PRIMARY KEY AUTOINCREMENT,
|
||||
device_uid TEXT NOT NULL REFERENCES devices(device_uid) ON DELETE CASCADE,
|
||||
blocked_count INTEGER NOT NULL DEFAULT 0,
|
||||
date TEXT NOT NULL,
|
||||
UNIQUE(device_uid, date)
|
||||
);
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_popup_rules_enabled ON popup_filter_rules(rule_type, enabled);
|
||||
Reference in New Issue
Block a user