You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
103 lines
3.5 KiB
103 lines
3.5 KiB
/** |
|
* 业务配置 |
|
* */ |
|
const url = location.host; |
|
const isDev = process.env.NODE_ENV === "development"; // 开发环境 |
|
const isHh = url.includes("10.196.131.73"); //是否河海版本 |
|
const isCH = url.includes("124.71.12.62"); //是否巢湖版本 |
|
const isPro = url.includes("occupationlab.com"); //是否职站生产 |
|
const isTest = url.includes('121.37.12.51'); //是否中台测试服 |
|
const isZxy = url.includes('izhixinyun'); //是否是智信云 |
|
const isSq = url.includes('10.20.100.204'); // 商丘 |
|
|
|
let zcPath = `120.78.139.126:8879` // 众筹 |
|
let systemPath = `${location.origin}/banksystem` |
|
let sandPath = `${location.origin}/sandbox` // 沙盘地址 |
|
let host = `${location.origin}/` |
|
// let host = `https://izhixinyun.com/` |
|
let uploadURL = `${location.origin}/` |
|
let title = isZxy ? |
|
'智信云' : |
|
(isHh || isCH) ? |
|
'学生端' : |
|
'职站' |
|
|
|
if (isDev) { |
|
// 本地 |
|
systemPath = `http://${location.hostname}:8093` |
|
sandPath = `http://${location.hostname}:9520` |
|
uploadURL = `http://121.37.12.51/` |
|
host = "http://121.37.12.51/"; // 测试服 |
|
// host = 'https://www.occupationlab.com/' // 正式服 |
|
const ip = localStorage.getItem('localIp') |
|
const ips = ['http://192.168.31.217:9000/', 'http://192.168.31.51:9000/', 'https://izhixinyun.com/'] |
|
host = ips[+ip] |
|
// host = 'http://192.168.31.51:9000/' |
|
} else if (isSq) { |
|
zcPath = `10.20.100.204:8883` |
|
} |
|
|
|
const Setting = { |
|
/** |
|
* 基础配置 |
|
* */ |
|
platformId: 1, // 平台标识,1职站,2数据平台,3中台 |
|
platformSource: 0, // 平台来源(0中台,1职站) |
|
titleSuffix: title, // 网页标题的后缀 |
|
routerMode: "hash", // 路由模式,可选值为 history 或 hash |
|
showProgressBar: true, // 页面切换时,是否显示模拟的进度条 |
|
apiBaseURL: host, // 接口请求地址 |
|
uploadURL, // 阿里云oss域名 |
|
systemPath, // 子系统地址前缀 |
|
sandPath, |
|
autoLogoutTime: 1000 * 60 * 60 * 3, // 长时间未操作,自动退出登录时间 |
|
modalDuration: 3, // 接口请求返回错误时,弹窗的持续时间,单位:秒 |
|
errorModalType: "Message", // 接口请求返回错误时,弹窗的类型,可选值为 Message 或 Notice |
|
cookiesExpires: 1, // Cookies 默认保存时间,单位:天 |
|
tokenExpires: 1296000000, // token在localStorage的时间(毫秒) |
|
tokenKey: "oc_client_token", // localStorage里保存的token的key |
|
storeKey: "oc_client_store", // localStorage里保存的vuex的key |
|
initialPassword: "1122aa", // 默认密码 |
|
isDev, |
|
isTest, |
|
isPro, |
|
isZxy, |
|
isSq, |
|
zcPath, |
|
/** |
|
* 路由白名单 |
|
* */ |
|
whiteList: ['/login', '/index/list', '/index/zxy', '/product/list', '/cityPartner/list', '/devPlatform/list', '/log/list', '/touristMatch/list', '/touristMatch/details', '/touristMatch/noticeDetail', '/preCourse/list', '/preCourse/details', '/preInfo/list', '/preInfo/details', '/screen', '/screenShow', '/screenShowPro', '/join', '/join/success'], |
|
/** |
|
* 平台列表 |
|
* */ |
|
platformList: [ |
|
{ |
|
id: 1, |
|
name: '职站' |
|
}, |
|
{ |
|
id: 2, |
|
name: '数据平台' |
|
}, |
|
{ |
|
id: 3, |
|
name: '中台' |
|
} |
|
], |
|
/** |
|
* 多语言配置 |
|
* */ |
|
i18n: { |
|
default: "zh", // 默认语言 |
|
auto: false // 是否根据用户电脑配置自动设置语言(仅第一次有效) |
|
}, |
|
layout: {}, // 布局配置 |
|
/** |
|
* 功能配置 |
|
* */ |
|
sameRouteForceUpdate: false, // 相同路由,不同参数间进行切换,是否强力更新 |
|
dynamicRoute: false // 是否使用动态路由 |
|
}; |
|
|
|
export default Setting;
|
|
|