对接数据
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
<IntegratedLayout>
|
||||
<div class="navigation-container">
|
||||
<div class="logo">
|
||||
<img src="/logo/white-logo.png" />
|
||||
<img src="/logo/white-logo.png" alt="" />
|
||||
<span>AIProdLaunch</span>
|
||||
</div>
|
||||
<div class="flex">
|
||||
@ -17,23 +17,21 @@
|
||||
<div v-if="activeMenu === item.path && item.meta.children" class="submenu">
|
||||
<div v-for="sub in item.children" :key="sub.path" @click.stop="goto(sub.path)"
|
||||
class="submenu-item pointer">
|
||||
<img :src="`/logo/${sub.meta.icon}.png`" />
|
||||
<img :src="`/logo/${sub.meta.icon}.png`" alt="" />
|
||||
{{ sub.name }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</IntegratedLayout>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
routes
|
||||
} from '../router';
|
||||
} from '~/router';
|
||||
|
||||
export default {
|
||||
name: "Header",
|
||||
@ -66,8 +64,8 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
handleParentClick(item) {
|
||||
// 只有没有子菜单时才跳转
|
||||
if (!item.children || item.children.length === 0) {
|
||||
const hasVisibleChildren = item.meta && !item.meta.children;
|
||||
if (hasVisibleChildren) {
|
||||
this.goto(item.path);
|
||||
}
|
||||
},
|
||||
@ -76,7 +74,6 @@ export default {
|
||||
* @param {String} path 导航的路径
|
||||
*/
|
||||
goto(path) {
|
||||
console.log(path)
|
||||
this.$router.push(path)
|
||||
},
|
||||
showSubmenu(item) {
|
||||
|
||||
Reference in New Issue
Block a user