From 46f142934e9d1d705fccb4a17220fec727fffb0b Mon Sep 17 00:00:00 2001 From: douzhuo <17611323298@163.com> Date: Wed, 19 Jan 2022 14:45:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E5=B9=B6=E8=AF=B7=E6=B1=82=E5=9F=9F?= =?UTF-8?q?=E5=90=8D=E5=88=B0domain?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config.js | 14 +------------- utils/domain.js | 29 +++++++++++++++++++++++++++++ utils/http.js | 7 +------ 3 files changed, 31 insertions(+), 19 deletions(-) create mode 100644 utils/domain.js diff --git a/config.js b/config.js index 6419d1c..ba7f0c4 100644 --- a/config.js +++ b/config.js @@ -1,16 +1,4 @@ -/** - * 小程序配置文件 - */ -// 此处主机域名修改成腾讯云解决方案分配的域名 -var host = 'http://121.42.63.138:9091/autoSR/api'; // 测试站 -// var host = 'http://192.168.31.169:8080/autoSR/api'; // 长龙 -// var host = 'http://192.168.31.134:8080/autoSR/api'; // 佳豪 -// var host = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 -// var host = 'https://zkgj.quhouse.com/api'; // 质控正式 -// var host = 'https://hfju.com/api'; // 数智正式 - - -var iMServiceHost = 'https://im.quhouse.com/'; //IM的后端地址正式 +import { host, iMServiceHost } from './utils/domain.js' var config = { service: { diff --git a/utils/domain.js b/utils/domain.js new file mode 100644 index 0000000..b1f4668 --- /dev/null +++ b/utils/domain.js @@ -0,0 +1,29 @@ +// http.js使用域名 +const baseUrl = 'http://121.42.63.138:9091/autoSR/api';// 测试站 +// const baseUrl = 'http://192.168.31.169:8080/autoSR/api'; // 长龙 +// const baseUrl = 'http://192.168.31.134:8080/autoSR/api'; // 佳豪 +// const baseUrl = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 +// const baseUrl = 'https://zkgj.quhouse.com/api'; // 质控正式 +// const baseUrl = 'https://hfju.com/api'; // 数智正式 + + +// config使用域名 +/** + * 小程序配置文件 + */ +// 此处主机域名修改成腾讯云解决方案分配的域名 +const host = 'http://121.42.63.138:9091/autoSR/api'; // 测试站 +// const host = 'http://192.168.31.169:8080/autoSR/api'; // 长龙 +// const host = 'http://192.168.31.134:8080/autoSR/api'; // 佳豪 +// const host = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 +// const host = 'https://zkgj.quhouse.com/api'; // 质控正式 +// const host = 'https://hfju.com/api'; // 数智正式 + + +const iMServiceHost = 'https://im.quhouse.com/'; //IM的后端地址正式 + +export { + baseUrl, + host, + iMServiceHost +} \ No newline at end of file diff --git a/utils/http.js b/utils/http.js index d9610ae..d61de6b 100644 --- a/utils/http.js +++ b/utils/http.js @@ -1,10 +1,5 @@ -const baseUrl = 'http://121.42.63.138:9091/autoSR/api';// 测试站 -// const baseUrl = 'http://192.168.31.169:8080/autoSR/api'; // 长龙 -// const baseUrl = 'http://192.168.31.134:8080/autoSR/api'; // 佳豪 -// const baseUrl = 'http://10.2.1.104:8081/autoSR/api'; // 刘敏 -// const baseUrl = 'https://zkgj.quhouse.com/api'; // 质控正式 -// const baseUrl = 'https://hfju.com/api'; // 数智正式 +import { baseUrl } from './domain.js' const install = (Vue, vm) => { Vue.prototype.$u.http.setConfig({