diff --git a/src/utils/api.js b/src/utils/api.js index ba05dfb..b0b0a95 100644 --- a/src/utils/api.js +++ b/src/utils/api.js @@ -2,12 +2,15 @@ // 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' }else{ host = 'http://www.occupationlab.com' + host2 = 'http://116.63.168.79' } -let host2 = 'http://116.63.168.79' + let host1 = 'http://39.108.250.202:8080' let uploadURL = 'http://8.134.8.197:8001' export default { @@ -25,7 +28,7 @@ export default { DeletePointOfJudgementRule: `${host}/judgment/pointOfJudgement/deletePointOfJudgementRule`, //删除判分点规则 UpdateIsOpen: `${host}/judgment/pointOfJudgement/updateIsOpen`, //修改判分点状态 JudgmentPointNameRepetition: `${host}/judgment/pointOfJudgement/JudgmentPointNameRepetition`, - queryUserIds:`${host}/liuwanr/userInfo/queryUserIds`, + queryUserIds:`/liuwanr/userInfo/queryUserIds`, // 科大 queryPoint: `${host2}/kdSys/queryPoint`, diff --git a/src/views/Home.vue b/src/views/Home.vue index 31017d4..aba7374 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -92,7 +92,8 @@ export default { currentPage: 1, systemId: "", userId: "", - systemName: "" + systemName: "", + host: location.host.includes('liuwanr.cn') ? 'http://www.liuwanr.cn' : 'http://www.occupationlab.com' }; }, components: {quill}, @@ -123,7 +124,7 @@ export default { }, handleCurrentChange(val) { - this.$get(this.api.queryUserIds).then(res => { + this.$get(`${this.host}${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 53986f7..7f83a57 100644 --- a/src/views/List.vue +++ b/src/views/List.vue @@ -83,7 +83,8 @@ export default { userId: this.$route.query.userId, pattern: this.$route.query.pattern, systemName: "", - searchTimer: null + searchTimer: null, + host: this.$route.query.host == 1 ? 'http://122.9.154.146' : 'http://116.63.168.79' }; }, components: {quill}, @@ -115,7 +116,7 @@ export default { }, handleCurrentChange(val) { - this.$get(this.api.queryUserIds).then(res => { + this.$get(`${this.host}${this.api.queryUserIds}`).then(res => { this.pageNo = val; let data = { systemId: this.systemId, diff --git a/src/views/ProgramOptions.vue b/src/views/ProgramOptions.vue index 0889317..b27bb46 100644 --- a/src/views/ProgramOptions.vue +++ b/src/views/ProgramOptions.vue @@ -493,6 +493,7 @@ export default { } }, getData() { + // pattern: 0基础,1挑战 this.$post(`${this.api.queryPoint}?challenge=${this.pattern}`) .then((res) => { this.stepList = res.subject