@lambo-design/pro-layout 1.0.0-beta.287 → 1.0.0-beta.288
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/src/components/pro-layout-header/pro-layout-nav/components/pro-layout-nav-slide-menu.vue
CHANGED
|
@@ -66,6 +66,9 @@ export default {
|
|
|
66
66
|
this.layoutSize = data.layoutSize ? data.layoutSize : 'default';
|
|
67
67
|
this.topMenuNum = data.topMenuNum ? data.topMenuNum : 4;
|
|
68
68
|
this.acceptAppId = data.acceptAppId ? data.acceptAppId : '';
|
|
69
|
+
if (!this.activeName) {
|
|
70
|
+
this.activeName = this.acceptAppId
|
|
71
|
+
}
|
|
69
72
|
this.initNav(this.navList)
|
|
70
73
|
}
|
|
71
74
|
},
|
|
@@ -100,21 +103,22 @@ export default {
|
|
|
100
103
|
this.selectApp(appId)
|
|
101
104
|
}
|
|
102
105
|
},
|
|
103
|
-
changeApp(appId, appInfo){
|
|
104
|
-
this.activeName = appId
|
|
105
|
-
},
|
|
106
106
|
selectApp(appId) {
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
107
|
+
if (appId) {
|
|
108
|
+
this.activeName = appId
|
|
109
|
+
let res = this.navList.filter(app => app.appId == appId)
|
|
110
|
+
Bus.$emit('change-app', { appId, appInfo: res[0] })
|
|
111
|
+
}
|
|
110
112
|
},
|
|
113
|
+
changeApp(appId, appInfo){
|
|
114
|
+
if (appId) {
|
|
115
|
+
this.activeName = appId
|
|
116
|
+
}
|
|
117
|
+
}
|
|
111
118
|
},
|
|
112
119
|
watch: {
|
|
113
120
|
acceptInt(val){
|
|
114
121
|
this.pointer = val;
|
|
115
|
-
},
|
|
116
|
-
acceptAppId(val) {
|
|
117
|
-
this.selectApp(val)
|
|
118
122
|
}
|
|
119
123
|
},
|
|
120
124
|
created() {
|
|
@@ -22,7 +22,7 @@ import Bus from '@lambo-design/shared/utils/bus'
|
|
|
22
22
|
import { deepCopy } from '@lambo-design/shared/utils/assist'
|
|
23
23
|
|
|
24
24
|
export default {
|
|
25
|
-
name: 'pro-layout-',
|
|
25
|
+
name: 'pro-layout-nav',
|
|
26
26
|
props: {
|
|
27
27
|
|
|
28
28
|
},
|
|
@@ -64,6 +64,9 @@ export default {
|
|
|
64
64
|
if (data) {
|
|
65
65
|
this.topMenuNum = data.topMenu ? data.topMenu : 4;
|
|
66
66
|
this.acceptAppId = data.acceptAppId ? data.acceptAppId : '';
|
|
67
|
+
if (!this.activeName) {
|
|
68
|
+
this.activeName = this.acceptAppId;
|
|
69
|
+
}
|
|
67
70
|
this.initNav(this.navList)
|
|
68
71
|
}
|
|
69
72
|
},
|
|
@@ -119,11 +122,6 @@ export default {
|
|
|
119
122
|
this.$nextTick(() => {
|
|
120
123
|
this.$refs.topNav.updateActiveName()
|
|
121
124
|
})
|
|
122
|
-
},
|
|
123
|
-
acceptAppId(val) {
|
|
124
|
-
if (val) {
|
|
125
|
-
this.selectApp(val)
|
|
126
|
-
}
|
|
127
125
|
}
|
|
128
126
|
},
|
|
129
127
|
created() {
|