From 8f802c5580edaf9dc86a811fd14db24726706f78 Mon Sep 17 00:00:00 2001 From: lb Date: Fri, 5 Aug 2022 09:35:05 +0800 Subject: [PATCH] update PUT-POST --- .../modules/monitoring/equipmenalarmlog-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipmenattr-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipmenfile-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipmengroup-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmengroupalarm-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipmenplc-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmenplcconnect-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmenplcparam-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmenquantity-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmenstatuslog-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipment-add-or-update.vue | 4 ++-- src/views/modules/monitoring/equipmentype-add-or-update.vue | 4 ++-- .../modules/monitoring/equipmentypefile-add-or-update.vue | 4 ++-- src/views/modules/monitoring/factory-add-or-update.vue | 4 ++-- src/views/modules/monitoring/producarrt-add-or-update.vue | 4 ++-- src/views/modules/monitoring/product-add-or-update.vue | 4 ++-- src/views/modules/monitoring/productionline-add-or-update.vue | 4 ++-- .../modules/monitoring/productionlinerecsch-add-or-update.vue | 4 ++-- .../modules/monitoring/qualityinspectiondet-add-or-update.vue | 4 ++-- .../monitoring/qualityinspectionrecord-add-or-update.vue | 4 ++-- .../monitoring/qualityinspectiontype-add-or-update.vue | 4 ++-- .../modules/monitoring/reporsheecategory-add-or-update.vue | 4 ++-- src/views/modules/monitoring/reporsheet-add-or-update.vue | 4 ++-- src/views/modules/monitoring/sysfile-add-or-update.vue | 4 ++-- src/views/modules/monitoring/sysfiletype-add-or-update.vue | 4 ++-- .../modules/monitoring/workshopsection-add-or-update.vue | 4 ++-- .../monitoring/workshopsectionequipment-add-or-update.vue | 4 ++-- 27 files changed, 54 insertions(+), 54 deletions(-) diff --git a/src/views/modules/monitoring/equipmenalarmlog-add-or-update.vue b/src/views/modules/monitoring/equipmenalarmlog-add-or-update.vue index 387e2a4..477ac91 100644 --- a/src/views/modules/monitoring/equipmenalarmlog-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenalarmlog-add-or-update.vue @@ -122,8 +122,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentAlarmLog/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentAlarmLog/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, alarmId: this.dataForm.alarmId, diff --git a/src/views/modules/monitoring/equipmenattr-add-or-update.vue b/src/views/modules/monitoring/equipmenattr-add-or-update.vue index a605795..c4d7656 100644 --- a/src/views/modules/monitoring/equipmenattr-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenattr-add-or-update.vue @@ -116,8 +116,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentAttr/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentAttr/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, equipmentId: this.dataForm.equipmentId, diff --git a/src/views/modules/monitoring/equipmenfile-add-or-update.vue b/src/views/modules/monitoring/equipmenfile-add-or-update.vue index ee1a5b0..626aae6 100644 --- a/src/views/modules/monitoring/equipmenfile-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenfile-add-or-update.vue @@ -140,8 +140,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentFile/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentFile/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, equipmentId: this.dataForm.equipmentId, diff --git a/src/views/modules/monitoring/equipmengroup-add-or-update.vue b/src/views/modules/monitoring/equipmengroup-add-or-update.vue index ae1bd3f..8d18cf5 100644 --- a/src/views/modules/monitoring/equipmengroup-add-or-update.vue +++ b/src/views/modules/monitoring/equipmengroup-add-or-update.vue @@ -122,8 +122,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentGroup/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentGroup/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/equipmengroupalarm-add-or-update.vue b/src/views/modules/monitoring/equipmengroupalarm-add-or-update.vue index 68edc30..f5ef505 100644 --- a/src/views/modules/monitoring/equipmengroupalarm-add-or-update.vue +++ b/src/views/modules/monitoring/equipmengroupalarm-add-or-update.vue @@ -152,8 +152,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentGroupAlarm/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentGroupAlarm/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, equipmentGroupId: this.dataForm.equipmentGroupId, diff --git a/src/views/modules/monitoring/equipmenplc-add-or-update.vue b/src/views/modules/monitoring/equipmenplc-add-or-update.vue index 2f39fb8..fcd16eb 100644 --- a/src/views/modules/monitoring/equipmenplc-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenplc-add-or-update.vue @@ -170,8 +170,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentPlc/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentPlc/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, plcType: this.dataForm.plcType, diff --git a/src/views/modules/monitoring/equipmenplcconnect-add-or-update.vue b/src/views/modules/monitoring/equipmenplcconnect-add-or-update.vue index 6d8d3d6..3a26db2 100644 --- a/src/views/modules/monitoring/equipmenplcconnect-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenplcconnect-add-or-update.vue @@ -116,8 +116,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentPlcConnect/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentPlcConnect/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, plcId: this.dataForm.plcId, diff --git a/src/views/modules/monitoring/equipmenplcparam-add-or-update.vue b/src/views/modules/monitoring/equipmenplcparam-add-or-update.vue index f77d44a..28f8210 100644 --- a/src/views/modules/monitoring/equipmenplcparam-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenplcparam-add-or-update.vue @@ -200,8 +200,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentPlcParam/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentPlcParam/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, plcConId: this.dataForm.plcConId, diff --git a/src/views/modules/monitoring/equipmenquantity-add-or-update.vue b/src/views/modules/monitoring/equipmenquantity-add-or-update.vue index c23eb1f..5f97249 100644 --- a/src/views/modules/monitoring/equipmenquantity-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenquantity-add-or-update.vue @@ -146,8 +146,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentQuantity/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentQuantity/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, externalCode: this.dataForm.externalCode, diff --git a/src/views/modules/monitoring/equipmenstatuslog-add-or-update.vue b/src/views/modules/monitoring/equipmenstatuslog-add-or-update.vue index cd8cfcf..462aaba 100644 --- a/src/views/modules/monitoring/equipmenstatuslog-add-or-update.vue +++ b/src/views/modules/monitoring/equipmenstatuslog-add-or-update.vue @@ -140,8 +140,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentStatusLog/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentStatusLog/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, externalCode: this.dataForm.externalCode, diff --git a/src/views/modules/monitoring/equipment-add-or-update.vue b/src/views/modules/monitoring/equipment-add-or-update.vue index d7079c9..4b00b94 100644 --- a/src/views/modules/monitoring/equipment-add-or-update.vue +++ b/src/views/modules/monitoring/equipment-add-or-update.vue @@ -200,8 +200,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipment/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipment/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/equipmentype-add-or-update.vue b/src/views/modules/monitoring/equipmentype-add-or-update.vue index 8a6113b..5833da1 100644 --- a/src/views/modules/monitoring/equipmentype-add-or-update.vue +++ b/src/views/modules/monitoring/equipmentype-add-or-update.vue @@ -134,8 +134,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentType/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentType/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/equipmentypefile-add-or-update.vue b/src/views/modules/monitoring/equipmentypefile-add-or-update.vue index 3cd5a2f..a9876b5 100644 --- a/src/views/modules/monitoring/equipmentypefile-add-or-update.vue +++ b/src/views/modules/monitoring/equipmentypefile-add-or-update.vue @@ -140,8 +140,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/equipmentTypeFile/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/equipmentTypeFile/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, equipmentTypeId: this.dataForm.equipmentTypeId, diff --git a/src/views/modules/monitoring/factory-add-or-update.vue b/src/views/modules/monitoring/factory-add-or-update.vue index b33ba1c..11164fc 100644 --- a/src/views/modules/monitoring/factory-add-or-update.vue +++ b/src/views/modules/monitoring/factory-add-or-update.vue @@ -134,8 +134,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/factory/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/factory/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/producarrt-add-or-update.vue b/src/views/modules/monitoring/producarrt-add-or-update.vue index cda5a00..cbf403e 100644 --- a/src/views/modules/monitoring/producarrt-add-or-update.vue +++ b/src/views/modules/monitoring/producarrt-add-or-update.vue @@ -140,8 +140,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/productArrt/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/productArrt/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/product-add-or-update.vue b/src/views/modules/monitoring/product-add-or-update.vue index 29b8a2f..6011f40 100644 --- a/src/views/modules/monitoring/product-add-or-update.vue +++ b/src/views/modules/monitoring/product-add-or-update.vue @@ -158,8 +158,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/product/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/product/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/productionline-add-or-update.vue b/src/views/modules/monitoring/productionline-add-or-update.vue index cb19afa..c204394 100644 --- a/src/views/modules/monitoring/productionline-add-or-update.vue +++ b/src/views/modules/monitoring/productionline-add-or-update.vue @@ -146,8 +146,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/productionLine/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/productionLine/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, factoryId: this.dataForm.factoryId, diff --git a/src/views/modules/monitoring/productionlinerecsch-add-or-update.vue b/src/views/modules/monitoring/productionlinerecsch-add-or-update.vue index 61509a2..ae297d7 100644 --- a/src/views/modules/monitoring/productionlinerecsch-add-or-update.vue +++ b/src/views/modules/monitoring/productionlinerecsch-add-or-update.vue @@ -86,8 +86,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/productionLineRecSch/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/productionLineRecSch/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, productionLineId: this.dataForm.productionLineId, diff --git a/src/views/modules/monitoring/qualityinspectiondet-add-or-update.vue b/src/views/modules/monitoring/qualityinspectiondet-add-or-update.vue index b0ae8a9..d79295d 100644 --- a/src/views/modules/monitoring/qualityinspectiondet-add-or-update.vue +++ b/src/views/modules/monitoring/qualityinspectiondet-add-or-update.vue @@ -116,8 +116,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/qualityInspectionDet/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/qualityInspectionDet/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, typeId: this.dataForm.typeId, diff --git a/src/views/modules/monitoring/qualityinspectionrecord-add-or-update.vue b/src/views/modules/monitoring/qualityinspectionrecord-add-or-update.vue index 7567531..1494951 100644 --- a/src/views/modules/monitoring/qualityinspectionrecord-add-or-update.vue +++ b/src/views/modules/monitoring/qualityinspectionrecord-add-or-update.vue @@ -146,8 +146,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/qualityInspectionRecord/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/qualityInspectionRecord/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, inspectionDetId: this.dataForm.inspectionDetId, diff --git a/src/views/modules/monitoring/qualityinspectiontype-add-or-update.vue b/src/views/modules/monitoring/qualityinspectiontype-add-or-update.vue index 3a130fc..7e53e32 100644 --- a/src/views/modules/monitoring/qualityinspectiontype-add-or-update.vue +++ b/src/views/modules/monitoring/qualityinspectiontype-add-or-update.vue @@ -110,8 +110,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/qualityInspectionType/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/qualityInspectionType/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, name: this.dataForm.name, diff --git a/src/views/modules/monitoring/reporsheecategory-add-or-update.vue b/src/views/modules/monitoring/reporsheecategory-add-or-update.vue index d8de149..57a6f6c 100644 --- a/src/views/modules/monitoring/reporsheecategory-add-or-update.vue +++ b/src/views/modules/monitoring/reporsheecategory-add-or-update.vue @@ -128,8 +128,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/reportSheetCategory/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/reportSheetCategory/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, code: this.dataForm.code, diff --git a/src/views/modules/monitoring/reporsheet-add-or-update.vue b/src/views/modules/monitoring/reporsheet-add-or-update.vue index 80ba6de..158ba4e 100644 --- a/src/views/modules/monitoring/reporsheet-add-or-update.vue +++ b/src/views/modules/monitoring/reporsheet-add-or-update.vue @@ -146,8 +146,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/reportSheet/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/reportSheet/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, category: this.dataForm.category, diff --git a/src/views/modules/monitoring/sysfile-add-or-update.vue b/src/views/modules/monitoring/sysfile-add-or-update.vue index 2639d72..2c12a2f 100644 --- a/src/views/modules/monitoring/sysfile-add-or-update.vue +++ b/src/views/modules/monitoring/sysfile-add-or-update.vue @@ -122,8 +122,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/sysFile/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/sysFile/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, typeCode: this.dataForm.typeCode, diff --git a/src/views/modules/monitoring/sysfiletype-add-or-update.vue b/src/views/modules/monitoring/sysfiletype-add-or-update.vue index 7a64e19..9123db8 100644 --- a/src/views/modules/monitoring/sysfiletype-add-or-update.vue +++ b/src/views/modules/monitoring/sysfiletype-add-or-update.vue @@ -110,8 +110,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/sysFileType/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/sysFileType/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, typeCode: this.dataForm.typeCode, diff --git a/src/views/modules/monitoring/workshopsection-add-or-update.vue b/src/views/modules/monitoring/workshopsection-add-or-update.vue index 343d9d9..9d016a4 100644 --- a/src/views/modules/monitoring/workshopsection-add-or-update.vue +++ b/src/views/modules/monitoring/workshopsection-add-or-update.vue @@ -140,8 +140,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/workShopSection/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/workShopSection/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, productionLineId: this.dataForm.productionLineId, diff --git a/src/views/modules/monitoring/workshopsectionequipment-add-or-update.vue b/src/views/modules/monitoring/workshopsectionequipment-add-or-update.vue index 2fc8b69..54984fd 100644 --- a/src/views/modules/monitoring/workshopsectionequipment-add-or-update.vue +++ b/src/views/modules/monitoring/workshopsectionequipment-add-or-update.vue @@ -116,8 +116,8 @@ export default { this.$refs['dataForm'].validate(valid => { if (valid) { this.$http({ - url: this.$http.adornUrl(`/monitoring/workShopSectionEquipment/${!this.dataForm.id ? 'save' : 'update'}`), - method: 'post', + url: this.$http.adornUrl(`/monitoring/workShopSectionEquipment/${!this.dataForm.id ? '' : this.dataForm.id}`), + method: this.dataForm.id ? 'put' : 'post', data: this.$http.adornData({ id: this.dataForm.id || undefined, workshopSectionId: this.dataForm.workshopSectionId,