优化bug

This commit is contained in:
13218645326 2023-12-10 03:13:22 +08:00
parent 8570c0c0c1
commit 7c2def08ab
5 changed files with 14 additions and 13 deletions

View File

@ -11,5 +11,5 @@ console.log('routedddd',route)
</script>
<style lang="scss">
@import url("./style/css/reset.css");
</style>

View File

@ -1,4 +1,5 @@
<template>
<!-- <h1>{{ navStore.topNavList }}</h1> -->
<subMenu :menuList="menuInfo.menuList" :collapse="menuInfo.collapse" :backgroundColor="menuInfo.backgroundColor"
:textColor="menuInfo.textColor" :activeTextColor="menuInfo.activeTextColor" :defaultActive="navStore.defaultActive"
:defaultOpeneds="menuInfo.defaultOpeneds" :uniqueOpened="menuInfo.uniqueOpened" :menuTrigger="menuInfo.menuTrigger"
@ -56,15 +57,15 @@ const initRouteList = () => {
const routes: any = list
console.log("routes", router)
const currentNav = routes.find((ele:any)=>ele.meta.folder).children[0]
if (navStore.topNavList.length == 0) {
let firstNav = {
title: currentNav.meta.title,
name: currentNav.name,
path: currentNav.path
}
navStore.addNavTarget(firstNav)
navStore.setCurrentNav(currentNav.path)
}
// if (navStore.topNavList.length == 0) {
// let firstNav = {
// title: currentNav.meta.title,
// name: currentNav.name,
// path: currentNav.path
// }
// navStore.addNavTarget(firstNav)
// navStore.setCurrentNav(currentNav.path)
// }
console.log("currentNav", currentNav)
menuInfo.defaultActive = currentNav.name + '&&' + currentNav.meta.title
console.log("currentNav", menuInfo.defaultActive)

View File

@ -73,7 +73,7 @@ const routes: Array<RouteRecordRaw> = [
{
path: 'enterpriseType',
name: 'configuration',
name: 'enterpriseType',
component: () => import('views/enterpriseManagement/enterpriseType/index.vue'),
meta: {
title: '企业类型',

View File

@ -1,6 +1,6 @@
@import '../css/reset.scss';
@import './variable.scss';
@import './mixin.scss';
@import './common.module.scss';
@import './nprogress.scss';
@import './common.scss';
@import '../css/reset.css';
@import './common.scss';