From 67f022d15637e276e8c9018a6629a6a1397dd815 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E5=87=AF?= <2448379534@qq.com> Date: Tue, 12 May 2026 14:34:58 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=20=E5=8F=B3=E4=BE=A7=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../JiuZhuZhanQingKuangJieShao.vue | 286 +++++++++++ .../xianZhiYanChenBianHua/index.vue | 203 ++++++++ frontend/src/modules/waterQuality/index.vue | 479 ++++++++++++++++++ frontend/src/permission.ts | 14 +- .../views/home/shuiDianKaiFaZhuangKuang.vue | 4 +- 5 files changed, 976 insertions(+), 10 deletions(-) create mode 100644 frontend/src/modules/DongWuJiuZhuZhan/JiuZhuZhanQingKuangJieShao.vue create mode 100644 frontend/src/modules/shengTaiLiuLiangXieFangSheShiMod/xianZhiYanChenBianHua/index.vue create mode 100644 frontend/src/modules/waterQuality/index.vue diff --git a/frontend/src/modules/DongWuJiuZhuZhan/JiuZhuZhanQingKuangJieShao.vue b/frontend/src/modules/DongWuJiuZhuZhan/JiuZhuZhanQingKuangJieShao.vue new file mode 100644 index 0000000..e1ac0ce --- /dev/null +++ b/frontend/src/modules/DongWuJiuZhuZhan/JiuZhuZhanQingKuangJieShao.vue @@ -0,0 +1,286 @@ + + + + + + \ No newline at end of file diff --git a/frontend/src/modules/shengTaiLiuLiangXieFangSheShiMod/xianZhiYanChenBianHua/index.vue b/frontend/src/modules/shengTaiLiuLiangXieFangSheShiMod/xianZhiYanChenBianHua/index.vue new file mode 100644 index 0000000..6e33b0f --- /dev/null +++ b/frontend/src/modules/shengTaiLiuLiangXieFangSheShiMod/xianZhiYanChenBianHua/index.vue @@ -0,0 +1,203 @@ + + + + + + \ No newline at end of file diff --git a/frontend/src/modules/waterQuality/index.vue b/frontend/src/modules/waterQuality/index.vue new file mode 100644 index 0000000..d8cb6b6 --- /dev/null +++ b/frontend/src/modules/waterQuality/index.vue @@ -0,0 +1,479 @@ + + + + + + + diff --git a/frontend/src/permission.ts b/frontend/src/permission.ts index d4ac5cb..ce1a107 100644 --- a/frontend/src/permission.ts +++ b/frontend/src/permission.ts @@ -16,17 +16,17 @@ function normalizeRoutes(routes: any[]): any[] { return routes.map(route => { // 创建副本以避免直接修改原始数据(可选,视具体需求而定) const normalizedRoute = { ...route }; - + // 修正当前路由的 path if (normalizedRoute.path && !normalizedRoute.path.startsWith('/')) { normalizedRoute.path = `/${normalizedRoute.path}`; } - + // 递归修正子路由 if (normalizedRoute.children && normalizedRoute.children.length > 0) { normalizedRoute.children = normalizeRoutes(normalizedRoute.children); } - + return normalizedRoute; }); } @@ -55,8 +55,6 @@ router.beforeEach(async (to, from, next) => { if (userStore.Token) { // 登录成功,跳转到首页 - if (to.path === '/login') { - //login if (to.path === '/login') { //login next({ path: '/' }); @@ -84,10 +82,12 @@ router.beforeEach(async (to, from, next) => { const { roles } = await userStore.getInfo(); let accessRoutes: RouteRecordRaw[] = await permissionStore.generateRoutes(roles); - + // ✅ 关键修复:在添加路由前,标准化所有路径 accessRoutes = normalizeRoutes(accessRoutes); + console.log('Normalized Access Routes:', accessRoutes); + accessRoutes.forEach((route: any) => { console.log('Adding Route:', route.path); router.addRoute(route); @@ -125,4 +125,4 @@ router.beforeEach(async (to, from, next) => { router.afterEach(() => { NProgress.done(); -}); +}); \ No newline at end of file diff --git a/frontend/src/views/home/shuiDianKaiFaZhuangKuang.vue b/frontend/src/views/home/shuiDianKaiFaZhuangKuang.vue index 17d7a41..b81a98d 100644 --- a/frontend/src/views/home/shuiDianKaiFaZhuangKuang.vue +++ b/frontend/src/views/home/shuiDianKaiFaZhuangKuang.vue @@ -29,14 +29,12 @@ const showMapModal = () => { modelStore.modalVisible = true; modelStore.params.sttp = "ENG"; modelStore.title = "三峡 详情信息"; - modelStore.currentTabKey = "basicInfo"; modelStore.isBasicEdit = true; }; const showMapModal1 = () => { modelStore.modalVisible = true; modelStore.params.sttp = "zh"; - modelStore.title = "三峡222 详情信息"; - modelStore.currentTabKey = "basicInfo"; + modelStore.title = "水质 详情信息"; modelStore.isBasicEdit = false; // modelStore.modalVisible = true; // modelStore.params.sttp = "zh"; From 1d8305707844e36a4f520d9acff07147d47bc46d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E5=87=AF?= <2448379534@qq.com> Date: Wed, 13 May 2026 08:45:15 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E5=9F=BA=E7=A1=80=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/MapModal/column.config.ts | 349 + .../MapModal/components/BasicInfo.vue | 10530 ++++++++-------- frontend/src/components/MapModal/index.vue | 1 + .../src/components/MapModal/setting.config.ts | 392 +- .../views/home/shuiDianKaiFaZhuangKuang.vue | 34 +- 5 files changed, 6147 insertions(+), 5159 deletions(-) diff --git a/frontend/src/components/MapModal/column.config.ts b/frontend/src/components/MapModal/column.config.ts index 8e17baa..33dbbb0 100644 --- a/frontend/src/components/MapModal/column.config.ts +++ b/frontend/src/components/MapModal/column.config.ts @@ -944,6 +944,351 @@ const BasicColumns: Array = [ } ]; +// 水温基础信息 + +const wtPointColumns: Array = [ + { + name: '基本属性', + visible: false, + ruleTips: '', + type: '', + url: '' + }, + { + name: '测站名称', + filed: 'stnm', + visible: true, + type: 'input', + url: '', + }, + { + name: '测站类型', + filed: 'sttpName', + visible: true, + type: 'select', + url: '', + }, + { + name: '站址', + filed: 'addvcdName', + visible: true, + type: 'input', + url: '', + }, + { + name: '所属流域', + filed: 'hbrvcdName', + visible: true, + type: 'select', + url: '', + }, + { + name: '经度(°)', + filed: 'lgtd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '纬度(°)', + filed: 'lttd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '建成日期', + filed: 'jcdt', + visible: true, + type: 'date', + format: 'YYYY-MM-DD', + url: '', + }, + { + name: '监测方式', + filed: 'mwayName', + visible: true, + type: 'select', + url: '', + }, + { + name: '所属电站', + filed: 'ennm', + visible: true, + type: 'select', + url: '', + }, + { + name: '', + filed: '', + visible: true, + type: '', + url: '', + }, + +]; +//水质基础信息 +const FhWpPointColumns: Array = [ + { + name: '基本属性', + visible: false, + ruleTips: '', + type: '', + url: '' + }, + { + name: '测站名称', + filed: 'stnm', + visible: true, + type: 'input', + url: '', + }, + { + name: '测站类型', + filed: 'sttpName', + visible: true, + type: 'select', + url: '', + }, + { + name: '站址', + filed: 'addvcdName', + visible: true, + type: 'input', + url: '', + }, + { + name: '所属流域', + filed: 'hbrvcdName', + visible: true, + type: 'select', + url: '', + }, + { + name: '经度(°)', + filed: 'lgtd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '纬度(°)', + filed: 'lttd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '类别', + filed: 'dtinTypeName', + visible: true, + type: 'select', + url: '', + }, + { + name: '水质要求', + filed: 'wwqtgName', + visible: true, + type: 'select', + url: '', + }, + { + name: '监测方式', + filed: 'mwayName', + visible: true, + type: 'select', + url: '', + }, + { + name: '', + filed: '', + visible: true, + type: '', + url: '', + }, + +]; +//栖息地基础信息 fh_point +const FhPointColumns: Array = [ + { + name: '基本属性', + visible: false, + ruleTips: '', + type: '', + url: '' + }, + { + name: '栖息地名称', + filed: 'stnm', + visible: true, + type: 'input', + url: '', + }, + { + name: '站址', + filed: 'stlc', + visible: true, + type: 'input', + url: '', + }, + { + name: '所属流域', + filed: 'baseName', + visible: true, + type: 'select', + url: '', + }, + { + name: '保护对象', + filed: 'protobj', + visible: true, + type: 'select', + url: '', + }, + { + name: '保护范围', + filed: 'qxdbhfw', + visible: true, + type: 'input', + url: '', + }, + { + name: '保护总长度(km)', + filed: 'qxdbhcd', + visible: true, + type: 'number', + toFixed: 2, + url: '', + }, + { + name: '保护核心长度(km)', + filed: 'qxdbhhxcd', + visible: true, + type: 'number', + toFixed: 2, + url: '', + }, + { + name: '保护外围长度', + filed: 'qxdbhwwcd', + visible: true, + type: 'number', + toFixed: 2, + url: '', + }, + { + name: '保护面积(km²)', + filed: 'qxdbhmj', + visible: true, + type: 'number', + toFixed: 2, + url: '', + }, + { + name: '保护河流', + filed: 'bhhl', + visible: true, + type: 'select', + url: '', + }, + { + name: '保护河段', + filed: 'bhhd', + visible: true, + type: 'select', + url: '', + }, + { + name: '保护措施', + filed: 'prottyp', + visible: true, + type: 'select', + url: '', + }, + { + name: '保护方式', + filed: 'protmthd', + visible: true, + type: 'select', + url: '', + }, + { + name: '投资(亿元)', + filed: 'inv', + visible: true, + type: 'number', + url: '', + }, + + +]; +//栖息地流量 基础信息 fh_zq_point +const FhZQPointColumns: Array = [ + { + name: '测站名称', + filed: 'stnm', + visible: true, + type: 'input', + url: '', + }, + { + name: '测站类型', + filed: 'sttpName', + visible: true, + type: 'select', + url: '', + }, + { + name: '站址', + filed: 'stlc', + visible: true, + type: 'input', + url: '', + }, + { + name: '所属流域', + filed: 'baseName', + visible: true, + type: 'select', + url: '', + }, + { + name: '经度(°)', + filed: 'lgtd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '纬度(°)', + filed: 'lttd', + visible: true, + type: 'number', + toFixed: 6, + url: '', + }, + { + name: '建成日期', + filed: 'jcdt', + visible: true, + type: 'date', + format: 'YYYY-MM-DD', + url: '', + }, + { + name: '监测方式', + filed: 'mwayName', + visible: true, + type: 'select', + url: '', + }, + +]; //阶段属性 const basicFilterColumns: Array = [ { @@ -1651,6 +1996,10 @@ const NormalColumns: Array = []; export { BasicColumns, + wtPointColumns, + FhWpPointColumns, + FhPointColumns, + FhZQPointColumns, basicFilterColumns, tabsWithTwoColumns, tableColumns1, diff --git a/frontend/src/components/MapModal/components/BasicInfo.vue b/frontend/src/components/MapModal/components/BasicInfo.vue index 3dca341..3f38d49 100644 --- a/frontend/src/components/MapModal/components/BasicInfo.vue +++ b/frontend/src/components/MapModal/components/BasicInfo.vue @@ -1,22 +1,13 @@