mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-12 12:26:44 +08:00
多环境测试
This commit is contained in:
@@ -5,20 +5,6 @@ export const deepCopy = (obj) => {
|
||||
return JSON.parse(JSON.stringify(obj));
|
||||
};
|
||||
|
||||
/**文件的基础路径*/
|
||||
export function getFileBaseUrl() {
|
||||
let protocol=window.location.protocol;
|
||||
let configPath=process.env.VUE_APP_FILE_BASE_URL;
|
||||
let baseUrl='';
|
||||
if(configPath.startsWith('http')){
|
||||
baseUrl = configPath;
|
||||
}else{
|
||||
let domain = window.location.host;
|
||||
baseUrl = protocol+'//'+domain+configPath;
|
||||
}
|
||||
return baseUrl;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取url协议
|
||||
* @param {Object} type
|
||||
|
||||
Reference in New Issue
Block a user