From 38919dfc8e909580c4b0246757ee42cc84e52bcc Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sun, 21 Sep 2025 21:59:01 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9A=E3=80=90antd=E3=80=91=E3=80=90ele?= =?UTF-8?q?=E3=80=91activeMenu=20=3D>=20activePath=20=E8=A7=A3=E5=86=B3?= =?UTF-8?q?=E6=BF=80=E6=B4=BB=E8=8F=9C=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../web-antd/src/router/routes/modules/bpm.ts | 2 +- .../web-antd/src/router/routes/modules/crm.ts | 16 +++++++------- .../src/router/routes/modules/infra.ts | 21 ++++++------------- .../src/router/routes/modules/mall.ts | 10 ++++----- apps/web-ele/src/router/routes/modules/diy.ts | 4 ++-- .../src/router/routes/modules/infra.ts | 21 ++++++------------- .../web-ele/src/router/routes/modules/mall.ts | 12 +++++------ 7 files changed, 34 insertions(+), 52 deletions(-) diff --git a/apps/web-antd/src/router/routes/modules/bpm.ts b/apps/web-antd/src/router/routes/modules/bpm.ts index 02e8b0b1..21abaabe 100644 --- a/apps/web-antd/src/router/routes/modules/bpm.ts +++ b/apps/web-antd/src/router/routes/modules/bpm.ts @@ -104,7 +104,7 @@ const routes: RouteRecordRaw[] = [ name: 'BpmProcessInstanceReport', meta: { title: '数据报表', - activeMenu: '/bpm/manager/model', + activePath: '/bpm/manager/model', icon: 'carbon:data-2', hideInMenu: true, keepAlive: true, diff --git a/apps/web-antd/src/router/routes/modules/crm.ts b/apps/web-antd/src/router/routes/modules/crm.ts index 15cb00e1..0f53404a 100644 --- a/apps/web-antd/src/router/routes/modules/crm.ts +++ b/apps/web-antd/src/router/routes/modules/crm.ts @@ -16,7 +16,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmClueDetail', meta: { title: '线索详情', - activeMenu: '/crm/clue', + activePath: '/crm/clue', }, component: () => import('#/views/crm/clue/modules/detail.vue'), }, @@ -25,7 +25,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmCustomerDetail', meta: { title: '客户详情', - activeMenu: '/crm/customer', + activePath: '/crm/customer', }, component: () => import('#/views/crm/customer/modules/detail.vue'), }, @@ -34,7 +34,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmBusinessDetail', meta: { title: '商机详情', - activeMenu: '/crm/business', + activePath: '/crm/business', }, component: () => import('#/views/crm/business/modules/detail.vue'), }, @@ -43,7 +43,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmContractDetail', meta: { title: '合同详情', - activeMenu: '/crm/contract', + activePath: '/crm/contract', }, component: () => import('#/views/crm/contract/modules/detail.vue'), }, @@ -52,7 +52,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmReceivablePlanDetail', meta: { title: '回款计划详情', - activeMenu: '/crm/receivable-plan', + activePath: '/crm/receivable-plan', }, component: () => import('#/views/crm/receivable/plan/modules/detail.vue'), @@ -62,7 +62,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmReceivableDetail', meta: { title: '回款详情', - activeMenu: '/crm/receivable', + activePath: '/crm/receivable', }, component: () => import('#/views/crm/receivable/modules/detail.vue'), }, @@ -71,7 +71,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmContactDetail', meta: { title: '联系人详情', - activeMenu: '/crm/contact', + activePath: '/crm/contact', }, component: () => import('#/views/crm/contact/modules/detail.vue'), }, @@ -80,7 +80,7 @@ const routes: RouteRecordRaw[] = [ name: 'CrmProductDetail', meta: { title: '产品详情', - activeMenu: '/crm/product', + activePath: '/crm/product', }, component: () => import('#/views/crm/product/modules/detail.vue'), }, diff --git a/apps/web-antd/src/router/routes/modules/infra.ts b/apps/web-antd/src/router/routes/modules/infra.ts index cc6d96de..c99b51be 100644 --- a/apps/web-antd/src/router/routes/modules/infra.ts +++ b/apps/web-antd/src/router/routes/modules/infra.ts @@ -2,7 +2,7 @@ import type { RouteRecordRaw } from 'vue-router'; const routes: RouteRecordRaw[] = [ { - path: '/infra/job/job-log', + path: '/infra/job/log', component: () => import('#/views/infra/job/logger/index.vue'), name: 'InfraJobLog', meta: { @@ -14,25 +14,16 @@ const routes: RouteRecordRaw[] = [ }, }, { - path: '/codegen', - name: 'CodegenEdit', + path: '/infra/codegen/edit', + component: () => import('#/views/infra/codegen/edit/index.vue'), + name: 'InfraCodegenEdit', meta: { - title: '代码生成', + title: '生成配置修改', icon: 'ic:baseline-view-in-ar', + activePath: '/infra/codegen', keepAlive: true, hideInMenu: true, }, - children: [ - { - path: '/codegen/edit', - name: 'InfraCodegenEdit', - component: () => import('#/views/infra/codegen/edit/index.vue'), - meta: { - title: '修改生成配置', - activeMenu: '/infra/codegen', - }, - }, - ], }, ]; diff --git a/apps/web-antd/src/router/routes/modules/mall.ts b/apps/web-antd/src/router/routes/modules/mall.ts index d5d39646..a2546dd1 100644 --- a/apps/web-antd/src/router/routes/modules/mall.ts +++ b/apps/web-antd/src/router/routes/modules/mall.ts @@ -16,7 +16,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuAdd', meta: { title: '商品添加', - activeMenu: '/mall/product/spu', + activePath: '/mall/product/spu', }, component: () => import('#/views/mall/product/spu/modules/form.vue'), }, @@ -25,7 +25,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuEdit', meta: { title: '商品编辑', - activeMenu: '/mall/product/spu', + activePath: '/mall/product/spu', }, component: () => import('#/views/mall/product/spu/modules/form.vue'), }, @@ -34,7 +34,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuDetail', meta: { title: '商品详情', - activeMenu: '/crm/business', + activePath: '/crm/business', }, component: () => import('#/views/mall/product/spu/modules/detail.vue'), }, @@ -55,7 +55,7 @@ const routes: RouteRecordRaw[] = [ name: 'TradeOrderDetail', meta: { title: '订单详情', - activeMenu: '/mall/trade/order', + activePath: '/mall/trade/order', }, component: () => import('#/views/mall/trade/order/modules/detail.vue'), }, @@ -64,7 +64,7 @@ const routes: RouteRecordRaw[] = [ name: 'TradeAfterSaleDetail', meta: { title: '退款详情', - activeMenu: '/mall/trade/after-sale', + activePath: '/mall/trade/after-sale', }, component: () => import('#/views/mall/trade/afterSale/modules/detail.vue'), diff --git a/apps/web-ele/src/router/routes/modules/diy.ts b/apps/web-ele/src/router/routes/modules/diy.ts index 78442f10..68bccd3c 100644 --- a/apps/web-ele/src/router/routes/modules/diy.ts +++ b/apps/web-ele/src/router/routes/modules/diy.ts @@ -17,7 +17,7 @@ const routes: RouteRecordRaw[] = [ name: 'DiyTemplateDecorate', meta: { title: '模板装修', - activeMenu: '/mall/promotion/diy-template/diy-template', + activePath: '/mall/promotion/diy-template/diy-template', }, component: () => import('#/views/mall/promotion/diy/template/modules/decorate.vue'), @@ -29,7 +29,7 @@ const routes: RouteRecordRaw[] = [ title: '页面装修', noCache: false, hidden: true, - activeMenu: '/mall/promotion/diy-template/diy-page', + activePath: '/mall/promotion/diy-template/diy-page', }, component: () => import('#/views/mall/promotion/diy/page/modules/decorate.vue'), diff --git a/apps/web-ele/src/router/routes/modules/infra.ts b/apps/web-ele/src/router/routes/modules/infra.ts index cc6d96de..c99b51be 100644 --- a/apps/web-ele/src/router/routes/modules/infra.ts +++ b/apps/web-ele/src/router/routes/modules/infra.ts @@ -2,7 +2,7 @@ import type { RouteRecordRaw } from 'vue-router'; const routes: RouteRecordRaw[] = [ { - path: '/infra/job/job-log', + path: '/infra/job/log', component: () => import('#/views/infra/job/logger/index.vue'), name: 'InfraJobLog', meta: { @@ -14,25 +14,16 @@ const routes: RouteRecordRaw[] = [ }, }, { - path: '/codegen', - name: 'CodegenEdit', + path: '/infra/codegen/edit', + component: () => import('#/views/infra/codegen/edit/index.vue'), + name: 'InfraCodegenEdit', meta: { - title: '代码生成', + title: '生成配置修改', icon: 'ic:baseline-view-in-ar', + activePath: '/infra/codegen', keepAlive: true, hideInMenu: true, }, - children: [ - { - path: '/codegen/edit', - name: 'InfraCodegenEdit', - component: () => import('#/views/infra/codegen/edit/index.vue'), - meta: { - title: '修改生成配置', - activeMenu: '/infra/codegen', - }, - }, - ], }, ]; diff --git a/apps/web-ele/src/router/routes/modules/mall.ts b/apps/web-ele/src/router/routes/modules/mall.ts index 809dc2e7..a0fdbdde 100644 --- a/apps/web-ele/src/router/routes/modules/mall.ts +++ b/apps/web-ele/src/router/routes/modules/mall.ts @@ -16,7 +16,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuAdd', meta: { title: '商品添加', - activeMenu: '/mall/product/spu', + activePath: '/mall/product/spu', }, component: () => import('#/views/mall/product/spu/modules/form.vue'), }, @@ -25,7 +25,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuEdit', meta: { title: '商品编辑', - activeMenu: '/mall/product/spu', + activePath: '/mall/product/spu', }, component: () => import('#/views/mall/product/spu/modules/form.vue'), }, @@ -34,7 +34,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpuDetail', meta: { title: '商品详情', - activeMenu: '/crm/business', + activePath: '/crm/business', }, component: () => import('#/views/mall/product/spu/modules/detail.vue'), }, @@ -43,7 +43,7 @@ const routes: RouteRecordRaw[] = [ name: 'ProductSpu', meta: { title: '商品列表', - activeMenu: '/mall/product/spu', + activePath: '/mall/product/spu', }, component: () => import('#/views/mall/product/spu/index.vue'), }, @@ -64,7 +64,7 @@ const routes: RouteRecordRaw[] = [ name: 'TradeOrderDetail', meta: { title: '订单详情', - activeMenu: '/mall/trade/order', + activePath: '/mall/trade/order', }, component: () => import('#/views/mall/trade/order/modules/detail.vue'), }, @@ -73,7 +73,7 @@ const routes: RouteRecordRaw[] = [ name: 'TradeAfterSaleDetail', meta: { title: '退款详情', - activeMenu: '/mall/trade/after-sale', + activePath: '/mall/trade/after-sale', }, component: () => import('#/views/mall/trade/afterSale/modules/detail.vue'),