import { defineConfig } from '@umijs/max'; export default defineConfig({ antd: {}, access: {}, model: {}, initialState: {}, request: {}, dva: {}, layout: false, publicPath: process.env.NODE_ENV == 'development' ? '/' : '/gt-dig/', metas: [ // 配置html禁止缓存 { 'http-equiv': 'pragma', content: 'no-cache' }, { 'http-equiv': 'cache-control', content: 'no-cache' }, { 'http-equiv': 'expires', content: '0' }, { 'http-equiv': 'X-UA-Compatible', content: 'IE=EmulateIE9' }, ], proxy: { '/api': { // target: 'http://47.96.12.136:8888/', target: 'http://47.96.12.136:8788/', // target: 'https://work.greentech.com.cn/', changeOrigin: true, }, }, routes: [ { path: '/', redirect: '/home', }, { name: '首页', path: '/home', component: './Home', }, { name: '工况管理', path: '/smart/work/:projectId', component: './Smart', }, { name: '工况评估', path: '/smart/condition-detection/:projectId', component: './Smart/ConditionDetection', }, { name: '优化任务', path: '/smart/optimization-tasks/:projectId', component: './Smart/OptimizationTasks', }, { name: '模拟仿真', path: '/smart/simulate/:projectId', component: './Smart/Simulate', }, { name: '系统自检', path: '/self-inspection/:projectId', component: './EqSelfInspection', }, { name: '自检报告', path: '/self-inspection/detail/:projectId/:routeId', component: './EqSelfInspection/ReportDetail', }, { name: '自检统计', path: '/self-inspection/statistics/:projectId', component: './EqSelfInspection/Statistics', }, { name: '任务管理', path: '/task-manage/:projectId', component: './TaskManage', }, // { // name: '权限演示', // path: '/access', // component: './Access', // }, // { // name: ' CRUD 示例', // path: '/table', // component: './Table', // }, ], npmClient: 'yarn', });