123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119 |
- import { RouteRecordRaw } from 'vue-router'
- export const staticRouter: RouteRecordRaw[] = [
- {
- path: '/',
- redirect: '/index'
- },
- {
- path: '/index',
- name: 'Index',
- component: () => import('@/views/Index.vue'),
- // redirect: '/home',
- meta: {
- title: '起始页'
- },
- children: [
- {
- path: '/saleMange',
- name: 'SaleMange',
- component: () => import('@/views/storehouse/sales/index.vue'),
- redirect: '/contract',
- meta: {
- routerView: true,
- title: '销售管理'
- },
- children: [
- {
- path: '/contractDetail/:id/:type',
- name: 'ContractDetail',
- component: () => import('@/views/storehouse/sales/ContractDetail.vue'),
- meta: {
- title: '合同详情'
- }
- }
- ]
- },
- {
- path: '/inventoryMange',
- name: 'InventoryMange',
- component: () => import('@/views/storehouse/inventory/index.vue'),
- redirect: '/contract',
- meta: {
- routerView: true,
- title: '库存管理'
- },
- children: [
- {
- path: '/inStorageDetail/:id',
- name: 'InStorageDetail',
- component: () => import('@/views/storehouse/inventory/InStorageDetail.vue'),
- meta: {
- title: '入库详情'
- }
- },
- {
- path: '/receiveOutStock',
- name: 'ReceiveOutStock',
- component: () => import('@/views/storehouse/outStock/ReceiveOutStock.vue'),
- meta: {
- title: '领料出库'
- }
- },
- {
- path: '/saleOutStock',
- name: 'SaleOutStock',
- component: () => import('@/views/storehouse/outStock/SaleOutStock.vue'),
- meta: {
- title: '销售出库'
- }
- },
- {
- path: '/outStockDetail/:number',
- name: 'OutStockDetail',
- component: () => import('@/views/storehouse/outStock/OutStockDetail.vue'),
- meta: {
- title: '出库详情'
- }
- }
- ]
- },
- {
- path: '/user',
- name: 'User',
- component: () => import('@/views/home/User.vue'),
- meta: {
- title: '个人中心'
- }
- }
- ]
- },
- {
- path: '/login',
- name: 'login',
- component: () => import('@/views/Login.vue'),
- meta: {
- title: '登录'
- }
- }
- ]
- export const errorRouter = [
- {
- path: '/404',
- name: '404',
- component: () => import('@/components/ErrorMessage/404.vue'),
- meta: {
- title: '404页面'
- }
- }
- ]
- /**
- * notFoundRouter(找不到路由)
- */
- export const notFoundRouter = {
- path: '/:pathMatch(.*)*',
- name: 'notFound',
- redirect: { name: '404' }
- }
|