### v1.0.7

### sql 脚本 - DDL

```sql
ALTER TABLE `data_permission` COMMENT = '数据权限表';

DROP TABLE IF EXISTS `upload_task`;
CREATE TABLE `upload_task`
(
    `id`          bigint(0)                                                      NOT NULL AUTO_INCREMENT COMMENT 'id',
    `user_id`     bigint(0)                                                      NULL DEFAULT NULL COMMENT '用户id',
    `username`    varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci   NULL DEFAULT NULL COMMENT '用户名',
    `remote_path` varchar(1024) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '远程路径',
    `description` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci  NULL DEFAULT NULL COMMENT '描述',
    `status`      char(16) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci      NULL DEFAULT NULL COMMENT '状态',
    `file_count`  int(0)                                                         NULL DEFAULT NULL COMMENT '文件数量',
    `host_count`  int(0)                                                         NULL DEFAULT NULL COMMENT '主机数量',
    `extra_info`  json                                                           NULL COMMENT '额外信息',
    `start_time`  datetime(3)                                                    NULL DEFAULT NULL COMMENT '开始时间',
    `end_time`    datetime(3)                                                    NULL DEFAULT NULL COMMENT '结束时间',
    `create_time` datetime(0)                                                    NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
    `update_time` datetime(0)                                                    NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
    `creator`     varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci   NULL DEFAULT NULL COMMENT '创建人',
    `updater`     varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci   NULL DEFAULT NULL COMMENT '更新人',
    `deleted`     tinyint(1)                                                     NULL DEFAULT 0 COMMENT '是否删除 0未删除 1已删除',
    PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB
  AUTO_INCREMENT = 1
  CHARACTER SET = utf8mb4
  COLLATE = utf8mb4_general_ci COMMENT = '上传任务'
  ROW_FORMAT = Dynamic;

DROP TABLE IF EXISTS `upload_task_file`;
CREATE TABLE `upload_task_file`
(
    `id`          bigint(0)                                                      NOT NULL AUTO_INCREMENT COMMENT 'id',
    `task_id`     bigint(0)                                                      NULL DEFAULT NULL COMMENT '用户id',
    `host_id`     bigint(0)                                                      NULL DEFAULT NULL COMMENT '主机id',
    `file_id`     varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci   NULL DEFAULT NULL COMMENT '文件id',
    `file_path`   varchar(1024) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '文件路径',
    `file_size`   bigint(0)                                                      NULL DEFAULT NULL COMMENT '文件大小',
    `status`      char(16) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci      NULL DEFAULT NULL COMMENT '状态',
    `start_time`  datetime(3)                                                    NULL DEFAULT NULL COMMENT '开始时间',
    `end_time`    datetime(3)                                                    NULL DEFAULT NULL COMMENT '结束时间',
    `create_time` datetime(0)                                                    NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
    `update_time` datetime(0)                                                    NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '修改时间',
    `creator`     varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci   NULL DEFAULT NULL COMMENT '创建人',
    `updater`     varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci   NULL DEFAULT NULL COMMENT '更新人',
    `deleted`     tinyint(1)                                                     NULL DEFAULT 0 COMMENT '是否删除 0未删除 1已删除',
    PRIMARY KEY (`id`) USING BTREE,
    INDEX `idx_task_id` (`task_id`) USING BTREE
) ENGINE = InnoDB
  AUTO_INCREMENT = 1
  CHARACTER SET = utf8mb4
  COLLATE = utf8mb4_general_ci COMMENT = '上传任务文件'
  ROW_FORMAT = Dynamic;
```

### sql 脚本 - DML

```sql
-- 字典项
DELETE FROM `dict_key` WHERE id >= 40;
INSERT INTO `dict_key` VALUES (40, 'sftpTransferStatus', 'STRING', '[{\"name\": \"status\", \"type\": \"STRING\"}, {\"name\": \"color\", \"type\": \"COLOR\"}, {\"name\": \"icon\", \"type\": \"STRING\"}]', 'SFTP 传输状态', '2024-05-06 11:54:49', '2024-05-06 11:54:49', '1', '1', 0);
INSERT INTO `dict_key` VALUES (41, 'uploadTaskStatus', 'STRING', '[{\"name\": \"color\", \"type\": \"COLOR\"}]', '上传任务状态', '2024-05-07 22:18:48', '2024-05-08 22:06:23', '1', '1', 0);
INSERT INTO `dict_key` VALUES (42, 'uploadTaskFileStatus', 'STRING', '[{\"name\": \"status\", \"type\": \"STRING\"}]', '上传任务文件状态', '2024-05-08 10:30:29', '2024-05-10 17:34:13', '1', '1', 0);
-- 字典值
DELETE FROM `dict_value` WHERE id >= 276;
INSERT INTO `dict_value` VALUES (276, 40, 'sftpTransferStatus', 'waiting', '传输中', '{\"icon\": \"icon-clock-circle\", \"color\": \"gray\", \"status\": \"waiting\"}', 10, '2024-05-06 12:00:04', '2024-05-06 12:00:04', '1', '1', 0);
INSERT INTO `dict_value` VALUES (277, 40, 'sftpTransferStatus', 'transferring', '传输中', '{\"icon\": \"icon-send\", \"color\": \"arcoblue\", \"status\": \"normal\"}', 20, '2024-05-06 12:01:22', '2024-05-06 12:01:22', '1', '1', 0);
INSERT INTO `dict_value` VALUES (278, 40, 'sftpTransferStatus', 'success', '已完成', '{\"icon\": \"icon-check\", \"color\": \"green\", \"status\": \"success\"}', 30, '2024-05-06 12:02:50', '2024-05-06 12:02:50', '1', '1', 0);
INSERT INTO `dict_value` VALUES (279, 40, 'sftpTransferStatus', 'error', '传输失败', '{\"icon\": \"icon-close\", \"color\": \"red\", \"status\": \"danger\"}', 40, '2024-05-06 12:03:27', '2024-05-06 12:03:27', '1', '1', 0);
INSERT INTO `dict_value` VALUES (280, 41, 'uploadTaskStatus', 'WAITING', '等待中', '{\"color\": \"gray\"}', 10, '2024-05-07 22:18:48', '2024-05-10 11:28:22', '1', '1', 0);
INSERT INTO `dict_value` VALUES (281, 41, 'uploadTaskStatus', 'UPLOADING', '上传中', '{\"color\": \"green\"}', 20, '2024-05-07 22:18:48', '2024-05-08 22:25:25', '1', '1', 0);
INSERT INTO `dict_value` VALUES (282, 41, 'uploadTaskStatus', 'FINISHED', '已完成', '{\"color\": \"arcoblue\"}', 30, '2024-05-07 22:18:48', '2024-05-08 22:25:50', '1', '1', 0);
INSERT INTO `dict_value` VALUES (283, 41, 'uploadTaskStatus', 'CANCELED', '已取消', '{\"color\": \"orange\"}', 50, '2024-05-07 22:18:48', '2024-05-10 11:28:56', '1', '1', 0);
INSERT INTO `dict_value` VALUES (284, 42, 'uploadTaskFileStatus', 'WAITING', '等待中', '{\"color\": \"gray\", \"status\": \"normal\"}', 10, '2024-05-08 10:30:29', '2024-05-10 17:35:30', '1', '1', 0);
INSERT INTO `dict_value` VALUES (285, 42, 'uploadTaskFileStatus', 'UPLOADING', '上传中', '{\"color\": \"green\", \"status\": \"normal\"}', 20, '2024-05-08 10:30:29', '2024-05-10 17:35:27', '1', '1', 0);
INSERT INTO `dict_value` VALUES (286, 42, 'uploadTaskFileStatus', 'FINISHED', '已完成', '{\"color\": \"arcoblue\", \"status\": \"success\"}', 30, '2024-05-08 10:30:29', '2024-05-10 17:35:15', '1', '1', 0);
INSERT INTO `dict_value` VALUES (287, 42, 'uploadTaskFileStatus', 'FAILED', '已失败', '{\"color\": \"red\", \"status\": \"danger\"}', 40, '2024-05-08 10:30:29', '2024-05-10 17:34:51', '1', '1', 0);
INSERT INTO `dict_value` VALUES (288, 42, 'uploadTaskFileStatus', 'CANCELED', '已取消', '{\"color\": \"orange\", \"status\": \"warning\"}', 50, '2024-05-08 10:30:29', '2024-05-10 17:34:30', '1', '1', 0);
INSERT INTO `dict_value` VALUES (289, 1, 'operatorLogModule', 'asset:upload-task', '批量上传', '{}', 2110, '2024-05-08 22:23:01', '2024-05-08 22:23:01', '1', '1', 0);
INSERT INTO `dict_value` VALUES (290, 2, 'operatorLogType', 'upload-task:upload', '批量上传文件', '{}', 10, '2024-05-08 22:23:27', '2024-05-08 22:23:27', '1', '1', 0);
INSERT INTO `dict_value` VALUES (291, 2, 'operatorLogType', 'upload-task:cancel', '取消上传文件', '{}', 20, '2024-05-08 22:23:36', '2024-05-08 22:23:36', '1', '1', 0);
INSERT INTO `dict_value` VALUES (292, 2, 'operatorLogType', 'upload-task:delete', '删除上传记录', '{}', 30, '2024-05-08 22:23:44', '2024-05-08 22:23:44', '1', '1', 0);
INSERT INTO `dict_value` VALUES (293, 2, 'operatorLogType', 'upload-task:clear', '清理上传记录', '{}', 40, '2024-05-08 22:23:59', '2024-05-08 22:23:59', '1', '1', 0);
INSERT INTO `dict_value` VALUES (294, 41, 'uploadTaskStatus', 'FAILED', '已失败', '{\"color\": \"red\"}', 40, '2024-05-10 11:29:17', '2024-05-10 11:29:17', '1', '1', 0);
-- 菜单
DELETE FROM `system_menu` WHERE id IN (152, 158, 161, 167, 172, 176, 177, 184, 185) OR id >= 192;
INSERT INTO `system_menu` VALUES (152, 0, '运维审计', NULL, 1, 410, 1, 1, 1, 0, 'IconSafe', NULL, 'assetAuditModule', '2024-01-04 17:54:56', '2024-04-28 15:30:04', '1', '1', 0);
INSERT INTO `system_menu` VALUES (158, 152, '文件操作日志', NULL, 2, 30, 1, 1, 1, 0, 'IconFile', NULL, 'sftpLog', '2024-03-05 15:30:13', '2024-05-07 11:11:24', '1', '1', 0);
INSERT INTO `system_menu` VALUES (161, 176, '执行模板', NULL, 2, 60, 1, 1, 1, 0, 'IconBookmark', NULL, 'execTemplate', '2024-03-07 18:32:41', '2024-04-28 17:14:30', '1', '1', 0);
INSERT INTO `system_menu` VALUES (167, 176, '执行日志', NULL, 2, 20, 1, 1, 1, 0, 'icon-history', NULL, 'execCommandLog', '2024-03-13 15:08:23', '2024-04-28 15:36:36', '1', '1', 0);
INSERT INTO `system_menu` VALUES (172, 176, '命令执行', NULL, 2, 10, 1, 1, 1, 0, 'icon-thunderbolt', NULL, 'execCommand', '2024-03-13 15:08:23', '2024-05-08 21:58:24', '1', '1', 0);
INSERT INTO `system_menu` VALUES (176, 0, '批量执行', NULL, 1, 420, 1, 1, 1, 0, 'icon-relation', NULL, 'execModule', '2024-04-10 16:13:27', '2024-04-28 15:30:31', '1', '1', 0);
INSERT INTO `system_menu` VALUES (177, 193, '任务列表', NULL, 2, 10, 1, 1, 1, 0, 'IconUnorderedList', NULL, 'execJob', '2024-04-10 16:13:27', '2024-04-28 15:36:10', '1', '1', 0);
INSERT INTO `system_menu` VALUES (184, 193, '任务日志', NULL, 2, 20, 1, 1, 1, 0, 'icon-history', '', 'execJobLog', '2024-04-11 13:40:47', '2024-04-28 15:34:27', '2', '1', 0);
INSERT INTO `system_menu` VALUES (185, 193, '计划任务日志新页面', NULL, 2, 30, 0, 1, 0, 1, NULL, NULL, 'execJobLogView', '2024-04-11 13:41:47', '2024-04-28 15:33:33', '2', '1', 0);
INSERT INTO `system_menu` VALUES (192, 0, '点个赞~', NULL, 1, 1030, 1, 1, 0, 1, 'IconThumbUp', 'https://github.com/lijiahangmax/orion-visor', NULL, '2024-04-26 11:32:30', '2024-05-06 17:33:16', '1', '1', 0);
INSERT INTO `system_menu` VALUES (193, 0, '计划任务', NULL, 1, 430, 1, 1, 1, 0, 'IconCalendarClock', NULL, 'jobModule', '2024-04-28 15:31:24', '2024-04-28 15:32:56', '1', '1', 0);
INSERT INTO `system_menu` VALUES (194, 152, '在线会话', NULL, 2, 20, 1, 1, 1, 0, 'IconUserGroup', NULL, 'connectSession', '2024-05-07 11:12:17', '2024-05-07 11:12:35', '1', '1', 0);
INSERT INTO `system_menu` VALUES (195, 194, '查询在线会话', 'asset:host-connect-session:management:query', 3, 10, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-07 11:13:16', '2024-05-07 11:13:16', '1', '1', 0);
INSERT INTO `system_menu` VALUES (196, 194, '强制断开连接', 'asset:host-connect-session:management:force-offline', 3, 20, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-07 11:13:37', '2024-05-07 11:13:37', '1', '1', 0);
INSERT INTO `system_menu` VALUES (197, 176, '批量上传', NULL, 2, 40, 1, 1, 1, 0, 'IconUpload', NULL, 'batchUpload', '2024-05-08 22:12:23', '2024-05-08 22:12:23', '1', '1', 0);
INSERT INTO `system_menu` VALUES (198, 176, '上传任务', NULL, 2, 50, 1, 1, 1, 0, 'IconCloud', NULL, 'uploadTask', '2024-05-08 22:16:05', '2024-05-10 23:09:58', '1', '1', 0);
INSERT INTO `system_menu` VALUES (199, 197, '上传文件', 'asset:upload-task:upload', 3, 10, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-08 22:19:35', '2024-05-08 22:19:35', '1', '1', 0);
INSERT INTO `system_menu` VALUES (200, 198, '查询上传日志', 'asset:upload-task:query', 3, 10, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-08 22:20:01', '2024-05-08 22:20:01', '1', '1', 0);
INSERT INTO `system_menu` VALUES (201, 198, '删除上传日志', 'asset:upload-task:delete', 3, 20, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-08 22:20:26', '2024-05-08 22:20:26', '1', '1', 0);
INSERT INTO `system_menu` VALUES (202, 198, '清理上传日志', 'asset:upload-task:management:clear', 3, 30, 1, 1, 1, 0, NULL, NULL, NULL, '2024-05-08 22:20:37', '2024-05-08 22:20:37', '1', '1', 0);
```
