From 6159ca7ab17d2f436685dd624d8cf407a69081a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=AD=A3=E6=98=93?= <9634538+git_rabbit@user.noreply.gitee.com> Date: Fri, 22 Mar 2024 10:18:54 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=93=E5=BA=93-=E6=88=90=E5=93=81=E5=BA=93?= =?UTF-8?q?=EF=BC=8C=E5=87=BA=E5=BA=93=E8=AE=B0=E5=BD=95=EF=BC=9A=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wmsManagement/wmGoodsNowProduction.js | 4 +- .../wmsManagement/WmGoodsNowProduction.vue | 734 +++++++++-------- .../wmsManagement/WmGoodsOutProduction.vue | 774 +++++++++--------- 3 files changed, 765 insertions(+), 747 deletions(-) diff --git a/src/api/wmsManagement/wmGoodsNowProduction.js b/src/api/wmsManagement/wmGoodsNowProduction.js index 40ebffb..498e80b 100644 --- a/src/api/wmsManagement/wmGoodsNowProduction.js +++ b/src/api/wmsManagement/wmGoodsNowProduction.js @@ -40,7 +40,7 @@ export function updateWmGoodsNowProduction(data) { */ export function getWmGoodsNowProduction(id) { return request({ - url: 'business/WmGoodsNowProduction/' + id, + url: '/mes/wm/WmGoodsNowProduction/' + id, method: 'get' }) } @@ -51,7 +51,7 @@ export function getWmGoodsNowProduction(id) { */ export function delWmGoodsNowProduction(pid) { return request({ - url: 'business/WmGoodsNowProduction/' + pid, + url: '/mes/wm/WmGoodsNowProduction/' + pid, method: 'delete' }) } diff --git a/src/views/wmsManagement/WmGoodsNowProduction.vue b/src/views/wmsManagement/WmGoodsNowProduction.vue index 583fe3e..9bf11e0 100644 --- a/src/views/wmsManagement/WmGoodsNowProduction.vue +++ b/src/views/wmsManagement/WmGoodsNowProduction.vue @@ -7,378 +7,390 @@ * @LastEditTime: (2024-03-22) --> \ No newline at end of file + this.form = { + ...data, + } + } + }) + }, + /** 提交按钮 */ + submitForm: function () { + this.$refs['form'].validate((valid) => { + if (valid) { + console.log(JSON.stringify(this.form)) + + if (this.form.id != undefined && this.opertype === 2) { + updateWmGoodsNowProduction(this.form) + .then((res) => { + this.msgSuccess('修改成功') + this.open = false + this.getList() + }) + .catch((err) => { + //TODO 错误逻辑 + }) + } else { + addWmGoodsNowProduction(this.form) + .then((res) => { + this.msgSuccess('新增成功') + this.open = false + this.getList() + }) + .catch((err) => { + //TODO 错误逻辑 + }) + } + } + }) + }, + }, +} + diff --git a/src/views/wmsManagement/WmGoodsOutProduction.vue b/src/views/wmsManagement/WmGoodsOutProduction.vue index 761b9cf..2097eb0 100644 --- a/src/views/wmsManagement/WmGoodsOutProduction.vue +++ b/src/views/wmsManagement/WmGoodsOutProduction.vue @@ -7,405 +7,411 @@ * @LastEditTime: (2024-03-22) --> \ No newline at end of file + this.form = { + ...data, + } + } + }) + }, + /** 提交按钮 */ + submitForm: function () { + this.$refs['form'].validate((valid) => { + if (valid) { + console.log(JSON.stringify(this.form)) + + if (this.form.id != undefined && this.opertype === 2) { + updateWmGoodsOutProduction(this.form) + .then((res) => { + this.msgSuccess('修改成功') + this.open = false + this.getList() + }) + .catch((err) => { + //TODO 错误逻辑 + }) + } else { + addWmGoodsOutProduction(this.form) + .then((res) => { + this.msgSuccess('新增成功') + this.open = false + this.getList() + }) + .catch((err) => { + //TODO 错误逻辑 + }) + } + } + }) + }, + }, +} +