From a03245633059e97a59fe833d43e24e7a590ae7dd Mon Sep 17 00:00:00 2001 From: "zhczyx@163.com" Date: Mon, 2 Mar 2026 23:22:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0trendLog=E5=9B=9B=E7=A7=8D?= =?UTF-8?q?=E5=A4=A7=E7=B1=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../db/migration/V71__category_add.sql | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 data-center-business-controller/src/main/resources/db/migration/V71__category_add.sql diff --git a/data-center-business-controller/src/main/resources/db/migration/V71__category_add.sql b/data-center-business-controller/src/main/resources/db/migration/V71__category_add.sql new file mode 100644 index 0000000..06ec8f2 --- /dev/null +++ b/data-center-business-controller/src/main/resources/db/migration/V71__category_add.sql @@ -0,0 +1,21 @@ +INSERT INTO `device_category` (`id`, `category_name_cn`, `category_name_jp`, `category_name_en`, `flag`) VALUES ('1007', '故障_TrendLog', '故障_TrendLog', '故障_TrendLog', '0'); +INSERT INTO `device_category` (`id`, `category_name_cn`, `category_name_jp`, `category_name_en`, `flag`) VALUES ('1008', '積算_TrendLog', '積算_TrendLog', '積算_TrendLog', '0'); +INSERT INTO `device_category` (`id`, `category_name_cn`, `category_name_jp`, `category_name_en`, `flag`) VALUES ('1009', '計測_TrendLog', '計測_TrendLog', '計測_TrendLog', '0'); +INSERT INTO `device_category` (`id`, `category_name_cn`, `category_name_jp`, `category_name_en`, `flag`) VALUES ('1010', '状態_TrendLog', '状態_TrendLog', '状態_TrendLog', '0'); + +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100701', 'TrendLog_Buffer_Size(126)(警報)', 'TrendLog_Buffer_Size', 'TrendLog_Buffer_Size', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Buffer_Size(警報)', 'TrendLog_Buffer_Size(警報)', '1007'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100702', 'TrendLog_Log_Buffer(131)(警報)', 'TrendLog_Log_Buffer', 'TrendLog_Log_Buffer', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Log_Buffer(警報)', 'TrendLog_Log_Buffer(警報)', '1007'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100703', 'TrendLog_Record_Count(141)(警報)', 'TrendLog_Record_Count', 'TrendLog_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Record_Count(警報)', 'TrendLog_Record_Count(警報)', '1007'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100704', 'TrendLog_Total_Record_Count(145)(警報)', 'TrendLog_Total_Record_Count', 'TrendLog_Total_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Total_Record_Count(警報)', 'TrendLog_Total_Record_Count(警報)', '1007'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100801', 'TrendLog_Buffer_Size(126)(積算)', 'TrendLog_Buffer_Size', 'TrendLog_Buffer_Size', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Buffer_Size(積算)', 'TrendLog_Buffer_Size(積算)', '1008'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100802', 'TrendLog_Log_Buffer(131)(積算)', 'TrendLog_Log_Buffer', 'TrendLog_Log_Buffer', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Log_Buffer(積算)', 'TrendLog_Log_Buffer(積算)', '1008'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100803', 'TrendLog_Record_Count(141)(積算)', 'TrendLog_Record_Count', 'TrendLog_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Record_Count(積算)', 'TrendLog_Record_Count(積算)', '1008'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100804', 'TrendLog_Total_Record_Count(145)(積算)', 'TrendLog_Total_Record_Count', 'TrendLog_Total_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Total_Record_Count(積算)', 'TrendLog_Total_Record_Count(積算)', '1008'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100901', 'TrendLog_Buffer_Size(126)(計測)', 'TrendLog_Buffer_Size', 'TrendLog_Buffer_Size', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Buffer_Size(計測)', 'TrendLog_Buffer_Size(計測)', '1009'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100902', 'TrendLog_Log_Buffer(131)(計測)', 'TrendLog_Log_Buffer', 'TrendLog_Log_Buffer', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Log_Buffer(計測)', 'TrendLog_Log_Buffer(計測)', '1009'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100903', 'TrendLog_Record_Count(141)(計測)', 'TrendLog_Record_Count', 'TrendLog_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Record_Count(計測)', 'TrendLog_Record_Count(計測)', '1009'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('100904', 'TrendLog_Total_Record_Count(145)(計測)', 'TrendLog_Total_Record_Count', 'TrendLog_Total_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Total_Record_Count(計測)', 'TrendLog_Total_Record_Count(計測)', '1009'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('101001', 'TrendLog_Buffer_Size(126)(状態)', 'TrendLog_Buffer_Size', 'TrendLog_Buffer_Size', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Buffer_Size(状態)', 'TrendLog_Buffer_Size(状態)', '1009'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('101002', 'TrendLog_Log_Buffer(131)(状態)', 'TrendLog_Log_Buffer', 'TrendLog_Log_Buffer', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Log_Buffer(状態)', 'TrendLog_Log_Buffer(状態)', '1010'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('101003', 'TrendLog_Record_Count(141)(状態)', 'TrendLog_Record_Count', 'TrendLog_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Record_Count(状態)', 'TrendLog_Record_Count(状態)', '1010'); +INSERT INTO `type` (`id`, `name`, `description`, `device_type`, `device_data_src`, `origin_json_format`, `expression_map`, `expression_variable_map`, `target_json_format`, `target_forward_id`, `target_foward_code`, `company_id`, `flag`, `dbm_id`, `name_zh`, `name_en`, `device_category_id`) VALUES ('101004', 'TrendLog_Total_Record_Count(145)(状態)', 'TrendLog_Total_Record_Count', 'TrendLog_Total_Record_Count', 'TrendLog', '[{\"id\":\"BA0029\",\"type\":\"Boolean\",\"reportedAt\":\"2022-12-11T13:50:00+09:00\",\"value\":false}]', '{\"$.deviceId\":\"$.id\",\"$.this\":\"getDeltaDataString($.this)\"}', '{\"getDeltaDataString($.this)\":{\"$.this\":\"$.this\"}}', '{\"deviceId\":\"$.Objs[0].N\"}', '1', '1', '2', '0', '[deviceSn]', 'TrendLog_Total_Record_Count(状態)', 'TrendLog_Total_Record_Count(状態)', '1010');