| | |
| | | import purchaseRouter from "./purchase/index.js" |
| | | import productRouter from "./product/index.js" |
| | | import {getMenuTreeByRole} from "@/api/menus/index" |
| | | import store from '@/store/index.js'; |
| | | |
| | | Vue.use(Router) |
| | | const login = (resolve) => require(["@/views/other/login/index"], resolve) |
| | |
| | | }; |
| | | const foundObject = res.data.list.find(obj => obj.systemType === 4); |
| | | if (foundObject) { |
| | | // 存储进vuex |
| | | store.commit('setMenus', foundObject); |
| | | foundObject.menus.forEach(item => { |
| | | const nextPath = item.children.find(obj => obj.path === routePath); |
| | | if (nextPath) { |