From fb7ca822609f9334a47bae42a797cef4f9acf035 Mon Sep 17 00:00:00 2001 From: valarchie <343928303@qq.com> Date: Fri, 25 Aug 2023 08:33:24 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=A7=A3=E5=86=B3=E6=B8=B2=E6=9F=93forr?= =?UTF-8?q?n.vue=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/router/utils.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/router/utils.ts b/src/router/utils.ts index cb0930c..06645f2 100644 --- a/src/router/utils.ts +++ b/src/router/utils.ts @@ -307,7 +307,8 @@ function addAsyncRoutes(arrRoutes: Array) { v.name = (v.children[0].name as string) + "Parent"; if (v.meta?.frameSrc) { v.component = IFrame; - } else { + } else if (!v.children) { + // 避免渲染form.vue组件 // 对后端传component组件路径和不传做兼容(如果后端传component组件路径,那么path可以随便写,如果不传,component组件路径会跟path保持一致) const index = v?.component ? modulesRoutesKeys.findIndex(ev => ev.includes(v.component as any))