文件名从 src/views/fysp/data-product/base-data-product/ProdManage.vue 修改 |
| | |
| | | <el-affix> |
| | | <el-menu |
| | | ref="menuRef" |
| | | default-active="scene" |
| | | :default-active="menu.length > 0 ? menu[0].path : ''" |
| | | ellipsis |
| | | mode="horizontal" |
| | | > |
| | |
| | | </template> |
| | | <script setup> |
| | | import { ref, onMounted, provide, inject, computed } from 'vue'; |
| | | import { useRouter, useRoute } from 'vue-router'; |
| | | import { useRouter } from 'vue-router'; |
| | | |
| | | const contentMaxHeight = inject('contentMaxHeight'); |
| | | |
| | | const props = defineProps({ |
| | | menu: { |
| | | type: Array, |
| | | default: () => [] |
| | | } |
| | | }) |
| | | |
| | | const router = useRouter(); |
| | | const route = useRoute(); |
| | | |
| | | const menuRef = ref(null); |
| | | const height = ref(contentMaxHeight.value); |
| | | |
| | | const menu = ref([ |
| | | { |
| | | name: '鍦烘櫙娓呭崟', |
| | | path: 'scene', |
| | | selected: true |
| | | }, |
| | | { |
| | | name: '璇勪及娓呭崟', |
| | | path: 'evaluate' |
| | | }, |
| | | { |
| | | name: '鏁存敼娓呭崟', |
| | | path: 'inspection' |
| | | }, |
| | | { |
| | | name: '鐩戞祴鏁版嵁', |
| | | path: 'monitorData' |
| | | } |
| | | ]); |
| | | // const menu = ref([ |
| | | // { |
| | | // name: '鍦烘櫙娓呭崟', |
| | | // path: 'scene', |
| | | // selected: true |
| | | // }, |
| | | // { |
| | | // name: '璇勪及娓呭崟', |
| | | // path: 'evaluate' |
| | | // }, |
| | | // { |
| | | // name: '鏁存敼娓呭崟', |
| | | // path: 'inspection' |
| | | // }, |
| | | // { |
| | | // name: '鐩戞祴鏁版嵁', |
| | | // path: 'monitorData' |
| | | // } |
| | | // ]); |
| | | |
| | | const navPage = (item) => { |
| | | if (item.index) { |