import Layout from "~src/layout/index.vue"; //路由菜单系统内置页面配置, noMenuBar: true 不显示在菜单栏记录里, isAuth: true 权限验证 export default [ { path: '/', redirect: '/home/index', }, { path: '/login', name: 'login', meta: {title: '登录'}, component: () => import('~src/views/login/index.vue') }, { path: '/home', name: 'home', redirect: '/home/index', meta: {title: '门户'}, component: Layout, children: [ //首页统计 { path: '/home/index', name: 'home-index', meta: {title: '普通权限'}, component: () => import('~src/views/home/index/index.vue') }, { path: '/home/admin', name: 'home-admin', meta: {title: '领导权限'}, component: () => import('~src/views/home/index/admin.vue') }, //审批管理 { path: '/home/task', name: 'home-task', meta: {title: '审批管理'}, component: () => import('~src/views/home/task/task.vue') }, { path: '/home/task-details', name: 'home-task-details', meta: {title: '任务详情', isAuth: true}, //, noMenuBar: true component: () => import('~src/views/home/task/task-details.vue') }, ], }, { path: '/project', name: 'project', redirect: '/project/index', meta: {title: '项目管理'}, component: Layout, children: [ //项目列表 { path: '/project/index', name: 'project-index', meta: {title: '项目列表'}, component: () => import('~src/views/project/list/index.vue') }, { path: '/project/list-info', name: 'project-list-info', meta: {title: '项目信息', isAuth: true}, component: () => import('~src/views/project/list/list-info.vue') }, //成本测算 { path: '/project/cost', name: 'project-cost', meta: {title: '成本测算'}, component: () => import('~src/views/project/cost/index.vue') }, { path: '/project/cost/form', name: 'project-cost-form', meta: {title: '成本测算', text: '新增编辑', isAuth: true}, component: () => import('~src/views/project/cost/form.vue') }, { path: '/project/cost-data', name: 'project-cost-data', meta: {title: '成本测算预览', isAuth: true}, component: () => import('~src/views/project/cost/data.vue') }, //项目合同 { path: '/project/contract', name: 'project-contract', meta: {title: '项目合同'}, component: () => import('~src/views/project/contract/index.vue') }, { path: '/project/contract/form', name: 'project-contract-form', meta: {title: '项目合同信息', isAuth: true}, component: () => import('~src/views/project/contract/form.vue') }, { path: '/project/contract/update', name: 'project-contract-update', meta: {title: '合同回款更新', isAuth: true}, component: () => import('~src/views/project/contract/update.vue') }, ], }, { path: '/program', name: 'program', redirect: '/program/annual', meta: {title: '预算计划管理'}, component: Layout, children: [ //年度经营预算 { path: '/program/annual', name: 'program-annual', meta: {title: '年度经营预算'}, component: () => import('~src/views/program/annual/index.vue') }, { path: '/program/annual-form', name: 'program-annual-form', meta: {title: '年度经营预算信息', isAuth: true}, component: () => import('~src/views/program/annual/form.vue') }, { path: '/program/annual-view', name: 'program-annual-view', meta: {title: '预览年度经营预算', isAuth: true}, component: () => import('~src/views/program/annual/view.vue') }, //项目计划预算 { path: '/program/project', name: 'program-project', meta: {title: '项目计划预算'}, component: () => import('~src/views/program/project/index.vue') }, { path: '/program/project-form', name: 'program-project-form', meta: {title: '项目计划预算信息', isAuth: true}, component: () => import('~src/views/program/project/form.vue') }, //部门月度计划预算 { path: '/program/section', name: 'program-section', meta: {title: '部门月度计划预算'}, component: () => import('~src/views/program/section/index.vue') }, { path: '/program/section-form', name: 'program-section-form', meta: {title: '部门月度计划预算信息', isAuth: true}, component: () => import('~src/views/program/section/form.vue') }, ], }, { path: '/task', name: 'task', redirect: '/task/logs', meta: {title: '任务管理'}, component: Layout, children: [ { path: '/task/logs', name: 'task-logs', meta: {title: '日志填报'}, component: () => import('~src/views/task/logs/index.vue') }, { path: '/task/plan', name: 'task-plan', meta: {title: '计划任务执行', isAuth: true}, component: () => import('~src/views/task/plan/index.vue') }, ], }, { path: '/expense', name: 'expense', redirect: '/expense/finReimburse', meta: {title: '费用管理'}, component: Layout, children: [ //财务报销 { path: '/expense/finReimburse', name: 'expense-finReimburse', meta: {title: '财务报销'}, component: () => import('~src/views/expense/finReimburse/index.vue') }, { path: '/expense/finReimburse/record', name: 'expense-finReimburse-record', meta: {title: '财务报销记录', isAuth: true}, component: () => import('~src/views/expense/finReimburse/record.vue') }, //支付申请 { path: '/expense/paymentRequest', name: 'expense-paymentRequest', meta: {title: '支付申请'}, component: () => import('~src/views/expense/paymentRequest/index.vue') }, { path: '/expense/paymentRequest/record', name: 'expense-paymentRequest-record', meta: {title: '支付申请记录', isAuth: true}, component: () => import('~src/views/expense/paymentRequest/record.vue') }, //借款申请 { path: '/expense/loanRequest', name: 'expense-loanRequest', meta: {title: '借款申请'}, component: () => import('~src/views/expense/loanRequest/index.vue') }, { path: '/expense/loanRequest/record', name: 'expense-loanRequest-record', meta: {title: '借款申请记录', isAuth: true}, component: () => import('~src/views/expense/loanRequest/record.vue') }, //采购申请 { path: '/expense/purchaseRequest', name: 'expense-purchaseRequest', meta: {title: '采购申请'}, component: () => import('~src/views/expense/purchaseRequest/index.vue') }, { path: '/expense/purchaseRequest/record', name: 'expense-purchaseRequest-record', meta: {title: '采购申请记录', isAuth: true}, component: () => import('~src/views/expense/purchaseRequest/record.vue') }, //用车申请 { path: '/expense/vehicleRequest', name: 'expense-vehicleRequest', meta: {title: '用车申请'}, component: () => import('~src/views/expense/vehicleRequest/index.vue') }, { path: '/expense/vehicleRequest/record', name: 'expense-vehicleRequest-record', meta: {title: '用车申请记录', isAuth: true}, component: () => import('~src/views/expense/vehicleRequest/record.vue') }, //发票管理 { path: '/expense/invoice', name: 'expense-invoice', meta: {title: '发票管理'}, component: () => import('~src/views/expense/invoice/index.vue') }, { path: '/expense/invoice/billing', name: 'expense-invoice-billing', meta: {title: '开票审批', isAuth: true}, component: () => import('~src/views/expense/invoice/billing.vue') }, //外包支付 { path: '/expense/outsourcing', name: 'expense-outsourcing', meta: {title: '外包支付'}, component: () => import('~src/views/expense/outsourcing/index.vue') }, { path: '/expense/outsourcing/record', name: 'expense-outsourcing-record', meta: {title: '外包支付记录', isAuth: true}, component: () => import('~src/views/expense/outsourcing/record.vue') }, ], }, { path: '/attendance', name: 'attendance', redirect: '/attendance/business-trip', meta: {title: '考勤管理'}, component: Layout, children: [ { path: '/attendance/business-trip', name: 'attendance-business-trip', meta: {title: '出差管理'}, component: () => import('~src/views//attendance/business-trip/index.vue') }, { path: '/attendance/business-trip-info', name: 'attendance-business-trip-info', meta: {title: '出差管理信息', isAuth: true}, component: () => import('~src/views//attendance/business-trip/info.vue') }, { path: '/attendance/statistic', name: 'attendance-statistic', meta: {title: '考勤统计'}, component: () => import('~src/views//attendance/statistic.vue') }, ], }, { path: '/user', name: 'user', redirect: '/user/index', meta: {title: '个人中心'}, component: Layout, children: [ { path: '/user/index', name: 'user-index', meta: {title: '个人资料', isAuth: true}, component: () => import('~src/views/user/index.vue') }, { path: '/user/config', name: 'user-config', meta: {title: '主题设置', isAuth: true}, component: () => import('~src/views/user/config.vue') }, ], }, { path: '/static', name: 'static', redirect: '/static/static', meta: {title: '综合查询统计'}, component: Layout, children: [ { path: '/static/actual', name: 'static-actual', meta: {title: '预算与实际统计'}, component: () => import('~src/views/static/actual.vue') }, { path: '/static/static', name: 'static-project', meta: {title: '项目统计'}, component: () => import('~src/views/static/project.vue') }, { path: '/static/plan', name: 'static-plan', meta: {title: '任务统计'}, component: () => import('~src/views/static/plan.vue') }, ], }, { path: '/system', name: 'system', redirect: '/system/user', meta: {title: '系统设置'}, component: Layout, children: [ { path: '/system/user', name: 'system-user', meta: {title: '账户管理'}, component: () => import('~src/views/system/user.vue') }, { path: '/system/menu', name: 'system-menu', meta: {title: '菜单管理'}, component: () => import('~src/views/system/menu.vue') }, { path: '/system/parameter', name: 'system-parameter', meta: {title: '参数配置'}, component: () => import('~src/views/system/parameter.vue') }, { path: '/system/organization', name: 'system-organization', meta: {title: '组织架构管理'}, component: () => import('~src/views/system/organization.vue') }, ], }, { path: '/people', name: 'people', redirect: '/people/company-rule', meta: {title: '人资管理'}, component: Layout, children: [ { path: '/people/company-rule', name: 'people-company-rule', meta: {title: '公司制度'}, component: () => import('~src/views/people/company-rule.vue') }, { path: '/people/archive', name: 'people-archive', meta: {title: '员工档案'}, component: () => import('~src/views/people/archive/index.vue') }, { path: '/people/archive-info', name: 'people-archive-info', meta: {title: '员工档案信息', isAuth: true}, component: () => import('~src/views/people/archive/info.vue') }, { path: '/people/contract', name: 'people-contract', meta: {title: '员工合同'}, component: () => import('~src/views/people/contract/index.vue') }, { path: '/people/contract-info', name: 'people-contract-info', meta: {title: '员工合同信息', isAuth: true}, component: () => import('~src/views/people/contract/info.vue') }, { path: '/people/salary', name: 'people-salary', meta: {title: '薪酬管理'}, component: () => import('~src/views/people/salary.vue') }, { path: '/people/entry', name: 'people-entry', meta: {title: '入职管理'}, component: () => import('~src/views/people/entry.vue') }, { path: '/people/dimission', name: 'people-dimission', meta: {title: '离职管理'}, component: () => import('~src/views/people/dimission.vue') }, ], }, // { // path: '/risk', // name: 'risk', // redirect: '/risk/warning', // meta: {title: '风险预警'}, // component: Layout, // children: [ // { // path: '/risk/warning', // name: 'risk-warning', // meta: {title: '风险预警'}, // component: () => import('~src/views/risk/warning.vue') // }, // ], // }, { path: '/403', name: '403', meta: {title: '403'}, component: () => import('~src/views/error/403.vue') }, { path: '/404', name: '404', meta: {title: '404'}, component: () => import('~src/views/error/404.vue') }, { path: '/500', name: '500', meta: {title: '500'}, component: () => import('~src/views/error/500.vue') }, { path: '/:path(.*)*', redirect: '/404' } ]