From dd696fd2e219ee1ac92d8e2564b33f99770493b8 Mon Sep 17 00:00:00 2001 From: yujialong <479214531@qq.com> Date: Wed, 2 Jun 2021 11:54:38 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E5=88=87=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/quill/index.vue | 1 - src/utils/api.js | 53 +++++++++++++++++++--------------- src/views/Home.vue | 2 +- src/views/List.vue | 2 +- 4 files changed, 31 insertions(+), 27 deletions(-) diff --git a/src/components/quill/index.vue b/src/components/quill/index.vue index c8c56a4..2276793 100644 --- a/src/components/quill/index.vue +++ b/src/components/quill/index.vue @@ -126,7 +126,6 @@ // 初始化编辑器 this.Quill = new Quill(editor, this.options); this.quillArr.push(this.Quill) - console.log(22,this.toref,this.Quill,this.quillArr) // 默认值 this.Quill.pasteHTML(this.currentValue); diff --git a/src/utils/api.js b/src/utils/api.js index b0b0a95..a701773 100644 --- a/src/utils/api.js +++ b/src/utils/api.js @@ -1,14 +1,17 @@ -// let host = 'http://192.168.31.117:8080' -// let host1 = 'http://192.168.31.152:8080' -// let host2 = 'http://192.168.31.152:9000'//榕 let host = '' -let host2 = '' -if(location.host.includes('liuwanr.cn')){ - host = 'http://www.liuwanr.cn' - host2 = 'http://122.9.154.146' +// 科大接口切换,参数里带host的为科大,否则就是职站中台 +let isKd = /&host=(\d)/.exec(location.hash) //host:{1:测试环境,2:正式环境} +if(isKd){ + host = isKd[1] == 1 ? 'http://122.9.154.146' : 'http://116.63.168.79' }else{ - host = 'http://www.occupationlab.com' - host2 = 'http://116.63.168.79' + // 职站中台接口切换 + if(location.host.includes('liuwanr.cn')){ + host = 'http://www.liuwanr.cn' + }else if(location.host.includes('occupationlab.com')){ + host = 'http://www.occupationlab.com' + }else{ + host = 'http://39.108.250.202' + } } let host1 = 'http://39.108.250.202:8080' @@ -16,6 +19,7 @@ let uploadURL = 'http://8.134.8.197:8001' export default { fileupload: `${uploadURL}/oss/manage/fileupload`, + // 职站 QueryPointOfJudgement: `${host}/judgment/pointOfJudgement/queryPointOfJudgement`, //判分点列表查询 DeletePointOfJudgement: `${host}/judgment/pointOfJudgement/deletePointOfJudgement`, //判分点列表删除 QueryPfdInformation: `${host}/judgment/pointOfJudgement/queryPfdInformation`, //判分点详细信息 @@ -28,24 +32,25 @@ export default { DeletePointOfJudgementRule: `${host}/judgment/pointOfJudgement/deletePointOfJudgementRule`, //删除判分点规则 UpdateIsOpen: `${host}/judgment/pointOfJudgement/updateIsOpen`, //修改判分点状态 JudgmentPointNameRepetition: `${host}/judgment/pointOfJudgement/JudgmentPointNameRepetition`, - queryUserIds:`/liuwanr/userInfo/queryUserIds`, + queryUserIds:`${host}/liuwanr/userInfo/queryUserIds`, - // 科大 - queryPoint: `${host2}/kdSys/queryPoint`, - querySubject: `${host2}/kdSys/querySubject`, - queryItem: `${host2}/kdSys/queryItem`, + // 科大子系统 + queryPoint: `${host}/kdSys/queryPoint`, + querySubject: `${host}/kdSys/querySubject`, + queryItem: `${host}/kdSys/queryItem`, - // 川大 + // 科大平台 + queryListTrading: `${host}/judgment/tradingJudgmentPoints/query`, + deleteTrading: `${host}/judgment/tradingJudgmentPoints/delete`, + addTrading: `${host}/judgment/tradingJudgmentPoints/add`, + queryDetailsTrading: `${host}/judgment/tradingJudgmentPoints/queryDetails`, + updateTrading: `${host}/judgment/tradingJudgmentPoints/update`, + updateRuleTrading: `${host}/judgment/tradingJudgmentPoints/updateRule`, + deleteRuleTrading: `${host}/judgment/tradingJudgmentPoints/deleteRule`, + addRule: `${host}/judgment/tradingJudgmentPoints/addRule`, + + // 川大子系统 firstLevel: `${host1}/sichuan/point/firstLevel`, secondaryLevel: `${host1}/sichuan/point/secondaryLevel`, thirdLevel: `${host1}/sichuan/point/thirdLevel`, - - queryListTrading: `${host2}/judgment/tradingJudgmentPoints/query`, - deleteTrading: `${host2}/judgment/tradingJudgmentPoints/delete`, - addTrading: `${host2}/judgment/tradingJudgmentPoints/add`, - queryDetailsTrading: `${host2}/judgment/tradingJudgmentPoints/queryDetails`, - updateTrading: `${host2}/judgment/tradingJudgmentPoints/update`, - updateRuleTrading: `${host2}/judgment/tradingJudgmentPoints/updateRule`, - deleteRuleTrading: `${host2}/judgment/tradingJudgmentPoints/deleteRule`, - addRule: `${host2}/judgment/tradingJudgmentPoints/addRule`, } \ No newline at end of file diff --git a/src/views/Home.vue b/src/views/Home.vue index aba7374..cb3e43b 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -124,7 +124,7 @@ export default { }, handleCurrentChange(val) { - this.$get(`${this.host}${this.api.queryUserIds}`).then(res => { + this.$get(`${this.api.queryUserIds}`).then(res => { this.pageNo = val; this.systemId = this.getCookie("systemId"); this.systemId = this.systemId ? this.systemId : 1 diff --git a/src/views/List.vue b/src/views/List.vue index 7f83a57..fef3987 100644 --- a/src/views/List.vue +++ b/src/views/List.vue @@ -116,7 +116,7 @@ export default { }, handleCurrentChange(val) { - this.$get(`${this.host}${this.api.queryUserIds}`).then(res => { + this.$get(`${this.api.queryUserIds}`).then(res => { this.pageNo = val; let data = { systemId: this.systemId,