update vuecli proxy

This commit is contained in:
2022-09-19 16:30:50 +08:00
parent 10e454eb2a
commit e532989ddf
12 changed files with 47 additions and 17 deletions

View File

@@ -11,8 +11,9 @@ export default {
return {
loading: true,
// url: process.env.VUE_APP_REPORT_DESIGN_URL
url: window.SITE_CONFIG['apiURL'] + '/yd-monitor/ureport/designer'
// url: window.SITE_CONFIG['apiURL'] + this.$http.adornUrl('/ureport/designer')
// url: this.$http.adornUrl('/ureport/designer')
url: (process.env.NODE_ENV === 'production' ? '/api' : '/yd-monitor') + '/ureport/designer'
}
},
mounted() {

View File

@@ -22,7 +22,8 @@ export default {
return {
loading: true,
// url: process.env.VUE_APP_REPORT_VIEW_URL
url: window.SITE_CONFIG['apiURL'] + '/yd-monitor/ureport/preview'
// url: window.SITE_CONFIG['apiURL'] + this.$http.adornUrl('/ureport/preview')
url: (process.env.NODE_ENV === 'production' ? '/api' : '/yd-monitor') + '/ureport/preview'
}
},
mounted() {

View File

@@ -230,7 +230,7 @@ export default {
type: 'warning'
}).then(() => {
this.$http({
url: '/yd-monitor/monitoring/workshopSectionEquipment',
url: this.$http.adornUrl('/monitoring/workshopSectionEquipment'),
method: 'delete',
data: [id]
}).then(({ data }) => {
@@ -274,7 +274,7 @@ export default {
},
handleCreateOrUpdate() {
this.$http({
url: '/yd-monitor/monitoring/workshopSection',
url: this.$http.adornUrl('/monitoring/workshopSection'),
method: this.dataForm.id ? 'put' : 'post',
data: {
...this.dataForm

View File

@@ -66,7 +66,7 @@ export default {
this.edit = true
// 获取信息,让用户修改排序
this.$http({
url: '/yd-monitor/monitoring/workshopSectionEquipment/' + id,
url: this.$http.adornUrl('/monitoring/workshopSectionEquipment/') + id,
method: 'get'
}).then(({ data: res }) => {
if (res.data) {
@@ -102,7 +102,7 @@ export default {
},
handleSave() {
this.$http({
url: '/yd-monitor/monitoring/workshopSectionEquipment',
url: this.$http.adornUrl('/monitoring/workshopSectionEquipment'),
method: this.edit ? 'put' : 'post',
data: {
...this.dataForm,