From 36af2c3515b5c061ac7d97e0c000cd4255e10450 Mon Sep 17 00:00:00 2001
From: 田源 <lastanimals@163.com>
Date: 星期日, 31 三月 2024 23:35:47 +0800
Subject: [PATCH] 动态路由
---
Source/ProjectWeb/src/router/page/index.js | 24 ++++++++++++------------
Source/ProjectWeb/src/components/refer/vciWebRefer.vue | 6 +++---
Source/ProjectWeb/src/components/dynamic-components/dynamic-form.vue | 2 +-
Source/ProjectWeb/src/router/router.js | 2 +-
4 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/Source/ProjectWeb/src/components/dynamic-components/dynamic-form.vue b/Source/ProjectWeb/src/components/dynamic-components/dynamic-form.vue
index f7373e3..5ef90db 100644
--- a/Source/ProjectWeb/src/components/dynamic-components/dynamic-form.vue
+++ b/Source/ProjectWeb/src/components/dynamic-components/dynamic-form.vue
@@ -248,7 +248,7 @@
this.formTemplateData = val;
},
setReferValue(data) {
- if (data.prop) {
+ if (data && data.prop) {
this.ruleForm[data.prop] = data.value || "";
this.ruleForm[data.showProp] = data.text || "";
if (data.propMap) {
diff --git a/Source/ProjectWeb/src/components/refer/vciWebRefer.vue b/Source/ProjectWeb/src/components/refer/vciWebRefer.vue
index ac98659..c07ef45 100644
--- a/Source/ProjectWeb/src/components/refer/vciWebRefer.vue
+++ b/Source/ProjectWeb/src/components/refer/vciWebRefer.vue
@@ -178,10 +178,10 @@
},
data() {
return {
- refertype: this.referConfig.options.type,
+ refertype: this.referConfig.type,
emitData: {},
- width:this.referConfig.options.width || '900px',
- height:this.referConfig.options.height || '500px'
+ width:this.referConfig.width || '900px',
+ height:this.referConfig.height || '500px'
};
},
computed: {
diff --git a/Source/ProjectWeb/src/router/page/index.js b/Source/ProjectWeb/src/router/page/index.js
index 657b0e0..d4946ac 100644
--- a/Source/ProjectWeb/src/router/page/index.js
+++ b/Source/ProjectWeb/src/router/page/index.js
@@ -77,18 +77,18 @@
path: '*',
redirect: '/404'
},
- {
- path: '/UIContentViewer',
- name: 'UI涓婁笅鏂�',
- component: Layout,
- children: [
- {
- path: '',
- component: () => import("@/views/base/UIContentViewer"),
- props: true
- }
- ]
- },
+ // {
+ // path: '/UIContentViewer',
+ // name: 'UI涓婁笅鏂�',
+ // component: Layout,
+ // children: [
+ // {
+ // path: '',
+ // component: () => import("@/views/base/UIContentViewer"),
+ // props: true
+ // }
+ // ]
+ // },
{
path: '/dynamic-form',
name: '鍔ㄦ�佽〃鏍奸〉闈�',
diff --git a/Source/ProjectWeb/src/router/router.js b/Source/ProjectWeb/src/router/router.js
index 9865153..798a1b0 100644
--- a/Source/ProjectWeb/src/router/router.js
+++ b/Source/ProjectWeb/src/router/router.js
@@ -27,7 +27,7 @@
i18n: i18n,
keepAlive: false,
});
-// Router.$avueRouter.formatRoutes(Store.state.user.menuAll, true); // 鍔ㄦ�佽矾鐢辨牳蹇冩柟娉�
+Router.$avueRouter.formatRoutes(Store.state.user.menuAll, true); // 鍔ㄦ�佽矾鐢辨牳蹇冩柟娉�
Router.addRoutes([...PageRouter, ...ViewsRouter]);
export function resetRouter () { // 閲嶇疆璺敱 姣斿鐢ㄤ簬韬唤楠岃瘉澶辫触锛岄渶瑕侀噸鏂扮櫥褰曟椂 鍏堟竻绌哄綋鍓嶇殑璺湁鏉冮檺
const newRouter = createRouter()
--
Gitblit v1.9.3