diff --git a/inquiry-api/jeecg-module-inquiry/src/main/java/org/jeecg/modules/inquiry/service/impl/InquiryResponseTimeoutServiceImpl.java b/inquiry-api/jeecg-module-inquiry/src/main/java/org/jeecg/modules/inquiry/service/impl/InquiryResponseTimeoutServiceImpl.java index 34fd36b..0fbd44b 100644 --- a/inquiry-api/jeecg-module-inquiry/src/main/java/org/jeecg/modules/inquiry/service/impl/InquiryResponseTimeoutServiceImpl.java +++ b/inquiry-api/jeecg-module-inquiry/src/main/java/org/jeecg/modules/inquiry/service/impl/InquiryResponseTimeoutServiceImpl.java @@ -41,6 +41,7 @@ public class InquiryResponseTimeoutServiceImpl private static final Map ID_TO_TIMEOUT_CODE = new LinkedHashMap<>(); static { + // 陆运产品仅保留 4 项运输分类(与线路解耦);旧逗号写法一次性纠偏 LAND_PRODUCT_TYPE_RENAMES.put( "普件,中港、东南亚常用线路/常规车型", "普件(东南亚、中港常用线路/常规车型)"); @@ -50,12 +51,6 @@ public class InquiryResponseTimeoutServiceImpl LAND_PRODUCT_TYPE_RENAMES.put( "普件,中亚、中欧、东南亚涉及境外段清派等特殊要求", "普件(东南亚、中亚、中欧涉及境外段清派等特殊要求)"); - LAND_PRODUCT_TYPE_RENAMES.put( - "普件,常用线路/常规车型", - "普件(常用线路/常规车型)"); - LAND_PRODUCT_TYPE_RENAMES.put( - "普件,非常用线路/临时线路/特种车型", - "普件(非常用线路/临时线路/特种车型)"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000001", "air_sales"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000002", "air_route"); @@ -63,19 +58,11 @@ public class InquiryResponseTimeoutServiceImpl ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000004", "land_sales"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000005", "sea_product_ptp"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000006", "sea_product_other"); + // 陆运产品运输分类 4 项(编码沿用 land_hk_*,勿再按线路拆 ltl/city/sea) ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000007", "land_hk_common"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000008", "land_hk_cross"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000009", "land_hk_special"); ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000010", "land_hk_express"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000011", "land_ltl_common"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000012", "land_ltl_special"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000013", "land_ltl_express"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000014", "land_city_common"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000015", "land_city_special"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000016", "land_city_express"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000017", "land_sea_common"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000018", "land_sea_special"); - ID_TO_TIMEOUT_CODE.put("rt100000000000000000000000000019", "land_sea_express"); } /** 本进程内只纠偏一次,避免每次打开系统设置都打 UPDATE */ diff --git a/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_code_v1.sql b/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_code_v1.sql index 96a8bb7..fc5001d 100644 --- a/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_code_v1.sql +++ b/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_code_v1.sql @@ -19,15 +19,7 @@ UPDATE `inq_response_timeout` SET `timeout_code`='land_hk_common' WHERE `id`='rt UPDATE `inq_response_timeout` SET `timeout_code`='land_hk_cross' WHERE `id`='rt100000000000000000000000000008' AND (`timeout_code` IS NULL OR `timeout_code`=''); UPDATE `inq_response_timeout` SET `timeout_code`='land_hk_special' WHERE `id`='rt100000000000000000000000000009' AND (`timeout_code` IS NULL OR `timeout_code`=''); UPDATE `inq_response_timeout` SET `timeout_code`='land_hk_express' WHERE `id`='rt100000000000000000000000000010' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_ltl_common' WHERE `id`='rt100000000000000000000000000011' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_ltl_special' WHERE `id`='rt100000000000000000000000000012' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_ltl_express' WHERE `id`='rt100000000000000000000000000013' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_city_common' WHERE `id`='rt100000000000000000000000000014' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_city_special' WHERE `id`='rt100000000000000000000000000015' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_city_express' WHERE `id`='rt100000000000000000000000000016' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_sea_common' WHERE `id`='rt100000000000000000000000000017' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_sea_special' WHERE `id`='rt100000000000000000000000000018' AND (`timeout_code` IS NULL OR `timeout_code`=''); -UPDATE `inq_response_timeout` SET `timeout_code`='land_sea_express' WHERE `id`='rt100000000000000000000000000019' AND (`timeout_code` IS NULL OR `timeout_code`=''); +-- 陆运产品仅 4 项;ltl/city/sea 重复行已由 migration_inq_response_timeout_land_class_v2.sql 删除 -- 3) 唯一索引(列已全部非空后再建;若仍有 NULL 会失败) UPDATE `inq_response_timeout` SET `timeout_code`=CONCAT('rt_', `id`) WHERE `timeout_code` IS NULL OR `timeout_code`=''; diff --git a/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_land_class_v2.sql b/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_land_class_v2.sql new file mode 100644 index 0000000..217ecfa --- /dev/null +++ b/inquiry-api/jeecg-module-inquiry/src/main/resources/db/migration_inq_response_timeout_land_class_v2.sql @@ -0,0 +1,59 @@ +-- 陆运产品运输分类:只保留产品确认的 4 项,删除按线路重复的 ltl/city/sea 共 9 条。 +-- 保留 land_hk_common / land_hk_cross / land_hk_special / land_hk_express,清空 route_category(分类与线路解耦)。 +-- 仅改 inquiry_robot;幂等可重复执行。 + +SET NAMES utf8mb4; + +-- 1) 删除按线路拆开的重复产品行 +DELETE FROM `inq_response_timeout` + WHERE `timeout_code` IN ( + 'land_ltl_common','land_ltl_special','land_ltl_express', + 'land_city_common','land_city_special','land_city_express', + 'land_sea_common','land_sea_special','land_sea_express' + ); + +DELETE FROM `inq_response_timeout` + WHERE `id` IN ( + 'rt100000000000000000000000000011', + 'rt100000000000000000000000000012', + 'rt100000000000000000000000000013', + 'rt100000000000000000000000000014', + 'rt100000000000000000000000000015', + 'rt100000000000000000000000000016', + 'rt100000000000000000000000000017', + 'rt100000000000000000000000000018', + 'rt100000000000000000000000000019' + ); + +-- 2) 保留的 4 项:分类与线路解耦,route_category 置空;文案对齐产品确认 +UPDATE `inq_response_timeout` + SET `route_category`='', + `transport_type`='普件(东南亚、中港常用线路/常规车型)', + `update_by`='system', + `update_time`=NOW() + WHERE `id`='rt100000000000000000000000000007' + OR `timeout_code`='land_hk_common'; + +UPDATE `inq_response_timeout` + SET `route_category`='', + `transport_type`='普件(东南亚、中亚、中欧涉及国内+国外段)', + `update_by`='system', + `update_time`=NOW() + WHERE `id`='rt100000000000000000000000000008' + OR `timeout_code`='land_hk_cross'; + +UPDATE `inq_response_timeout` + SET `route_category`='', + `transport_type`='普件(东南亚、中亚、中欧涉及境外段清派等特殊要求)', + `update_by`='system', + `update_time`=NOW() + WHERE `id`='rt100000000000000000000000000009' + OR `timeout_code`='land_hk_special'; + +UPDATE `inq_response_timeout` + SET `route_category`='', + `transport_type`='急件', + `update_by`='system', + `update_time`=NOW() + WHERE `id`='rt100000000000000000000000000010' + OR `timeout_code`='land_hk_express'; diff --git a/inquiry-backend/src/views/inquiry/systemSetting/index.vue b/inquiry-backend/src/views/inquiry/systemSetting/index.vue index f209d76..a3d3d85 100644 --- a/inquiry-backend/src/views/inquiry/systemSetting/index.vue +++ b/inquiry-backend/src/views/inquiry/systemSetting/index.vue @@ -4,7 +4,7 @@ * 海运 / 空运 / 陆运同页自上而下分块展示,只允许改超时小时;无增删、无 Tab。 * 「编码」= timeoutCode,每条唯一(如 sea_sales / land_hk_express),供智能体单码调用;只读。 * roleCode(销售/产品)仅为角色维度,可重复,不是调用主键。 - * 不展示线路类别(维度仍在主账,仅后台列表隐藏)。 + * 陆运产品运输分类仅 4 项(与线路解耦);不展示线路类别。 * 数据来自主账 inq_response_timeout;本页不做工单超时判定。 */ import { computed, onMounted, ref } from 'vue';