修改请求后缀
This commit is contained in:
parent
761d28de86
commit
3f7f1877ae
|
|
@ -13,13 +13,13 @@ module.exports = {
|
|||
assetsPublicPath: '/',
|
||||
// 代理列表, 是否开启代理通过[./dev.env.js]配置
|
||||
proxyTable: devEnv.OPEN_PROXY === false ? {} : {
|
||||
'/sqx_fast': {
|
||||
// target: 'http://192.168.0.132:8184/sqx_fast/',
|
||||
// target: 'https://duanjudl.xianmxkj.com/sqx_fast/',
|
||||
target: 'http://127.0.0.1/sqx_fast/',
|
||||
'/czg': {
|
||||
// target: 'http://192.168.0.132:8184/czg/',
|
||||
// target: 'https://duanjudl.xianmxkj.com/czg/',
|
||||
target: 'http://127.0.0.1/czg/',
|
||||
changeOrigin: true,
|
||||
pathRewrite: {
|
||||
'^/sqx_fast': ''
|
||||
'^/czg': ''
|
||||
}
|
||||
},
|
||||
},
|
||||
|
|
|
|||
|
|
@ -13,9 +13,9 @@ const http = axios.create({
|
|||
}
|
||||
})
|
||||
|
||||
// const requestURl = "http://localhost:8100/sqx_fast/";
|
||||
const requestURl = "https://video.hnsiyao.cn/sqx_fast/";
|
||||
// const requestURl = "https://dj-api.hnsiyao.cn/sqx_fast/";
|
||||
// const requestURl = "http://localhost:8100/czg/";
|
||||
const requestURl = "https://video.hnsiyao.cn/czg/";
|
||||
// const requestURl = "https://dj-api.hnsiyao.cn/czg/";
|
||||
|
||||
/**
|
||||
* 请求拦截
|
||||
|
|
@ -48,8 +48,8 @@ http.interceptors.response.use(response => {
|
|||
http.adornUrl = (actionName) => {
|
||||
// 非生产环境 && 开启代理, 接口前缀统一使用[/proxyApi/]前缀做代理拦截!
|
||||
// return (process.env.NODE_ENV !== 'production' && process.env.OPEN_PROXY ? '/proxyApi/' : window.SITE_CONFIG.baseUrl) + actionName
|
||||
// return 'http://192.168.0.132:8184/sqx_fast/' + actionName
|
||||
// return 'https://duanjudl.xianmxkj.co/sqx_fast/' + actionName
|
||||
// return 'http://192.168.0.132:8184/czg/' + actionName
|
||||
// return 'https://duanjudl.xianmxkj.co/czg/' + actionName
|
||||
actionName = actionName.replace(/^\//, "");
|
||||
return requestURl + actionName
|
||||
|
||||
|
|
@ -57,8 +57,8 @@ http.adornUrl = (actionName) => {
|
|||
http.adornUrlUp = (actionName) => {
|
||||
// 非生产环境 && 开启代理, 接口前缀统一使用[/proxyApi/]前缀做代理拦截!
|
||||
// return (process.env.NODE_ENV !== 'production' && process.env.OPEN_PROXY ? '/proxyApi/' : window.SITE_CONFIG.baseUrl) + actionName
|
||||
// return 'http://192.168.0.132:8183/sqx_fast/' + actionName
|
||||
// return 'https://duanjudl.xianmxkj.co/sqx_fast/' + actionName
|
||||
// return 'http://192.168.0.132:8183/czg/' + actionName
|
||||
// return 'https://duanjudl.xianmxkj.co/czg/' + actionName
|
||||
actionName = actionName.replace(/^\//, "");
|
||||
return requestURl + actionName
|
||||
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@
|
|||
>登录</el-button
|
||||
>
|
||||
</div>
|
||||
<div>
|
||||
<!-- <div>
|
||||
<el-button
|
||||
class="login-btn-submit"
|
||||
plain
|
||||
|
|
@ -94,7 +94,7 @@
|
|||
@click="isLogin = false"
|
||||
>注册</el-button
|
||||
>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item v-if="!isLogin">
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@
|
|||
|
||||
xhr = new XMLHttpRequest();
|
||||
xhr.withCredentials = false;
|
||||
xhr.open('POST', "https://duanjudl.xianmxkj.co/sqx_fast/alioss/upload");
|
||||
xhr.open('POST', "https://duanjudl.xianmxkj.co/czg/alioss/upload");
|
||||
xhr.onload = function () {
|
||||
var json;
|
||||
|
||||
|
|
|
|||
|
|
@ -191,7 +191,7 @@
|
|||
|
||||
xhr = new XMLHttpRequest();
|
||||
xhr.withCredentials = false;
|
||||
xhr.open('POST', "https://duanjudl.xianmxkj.co/sqx_fast/alioss/upload");
|
||||
xhr.open('POST', "https://duanjudl.xianmxkj.co/czg/alioss/upload");
|
||||
xhr.onload = function () {
|
||||
var json;
|
||||
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@
|
|||
</td>
|
||||
<th>图像</th>
|
||||
<td class="border-rt">
|
||||
<img :src="tableData.avatar ? tableData.avatar : 'https://duanjudl.xianmxkj.co/sqx_fast/logo.png'"
|
||||
<img :src="tableData.avatar ? tableData.avatar : 'https://duanjudl.xianmxkj.co/czg/logo.png'"
|
||||
width="80" height="80" />
|
||||
<el-button size="mini" :disabled="!isAuth('userList:update')"
|
||||
style="color: #4f9dec;background: #fff;border: none;"
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@
|
|||
<th>图像</th>
|
||||
<td class="border-rt">
|
||||
<img
|
||||
:src="tableData.avatar ? tableData.avatar : 'https://duanjudl.xianmxkj.co/sqx_fast/logo.png'"
|
||||
:src="tableData.avatar ? tableData.avatar : 'https://duanjudl.xianmxkj.co/czg/logo.png'"
|
||||
width="80" height="80" />
|
||||
<el-button size="mini" :disabled="!isAuth('userList:update')"
|
||||
style="color: #4f9dec;background: #fff;border: none;" @click="ageChangeU(tableData)">
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
window.SITE_CONFIG = {};
|
||||
|
||||
// api接口请求地址
|
||||
window.SITE_CONFIG['baseUrl'] = 'https://ditanxiong.gomyorder.cn/sqx_fast';
|
||||
window.SITE_CONFIG['baseUrl'] = 'https://ditanxiong.gomyorder.cn/czg';
|
||||
|
||||
// cdn地址 = 域名 + 版本号
|
||||
window.SITE_CONFIG['domain'] = './'; // 域名
|
||||
|
|
|
|||
Loading…
Reference in New Issue