From 675af0d52e8ebaa4b8c92b56c9e718cdc496546b Mon Sep 17 00:00:00 2001 From: mengjiao <3338049200@qq,com> Date: Mon, 11 Nov 2024 15:17:43 +0800 Subject: [PATCH] =?UTF-8?q?wms=E7=89=B9=E6=AE=8A=E6=94=B6=E8=B4=A7?= =?UTF-8?q?=E6=94=B92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wms/bpprocure.js | 7 ++++--- src/views/wms/bpprocure/index.vue | 29 ++++++----------------------- 2 files changed, 10 insertions(+), 26 deletions(-) diff --git a/src/api/wms/bpprocure.js b/src/api/wms/bpprocure.js index c878f95..d636f54 100644 --- a/src/api/wms/bpprocure.js +++ b/src/api/wms/bpprocure.js @@ -36,9 +36,10 @@ export function updateBpprocure(data) { } // 删除白坯原材料采购单 -export function delBpprocure(ID) { +export function delBpprocure(IDs) { return request({ - url: '/wms/bpprocure/' + ID, - method: 'delete' + url: '/wms/bpprocure/remove', + method: 'post', + data: IDs }) } diff --git a/src/views/wms/bpprocure/index.vue b/src/views/wms/bpprocure/index.vue index cc629c9..058ab3b 100644 --- a/src/views/wms/bpprocure/index.vue +++ b/src/views/wms/bpprocure/index.vue @@ -82,6 +82,7 @@ + @@ -91,24 +92,6 @@ - - - item.ID) + this.ids = selection.map(item => item.id) this.single = selection.length!==1 this.multiple = !selection.length }, @@ -294,7 +277,7 @@ export default { /** 修改按钮操作 */ handleUpdate(row) { this.reset(); - const ID = row.ID || this.ids + const ID = row.id || this.ids getBpprocure(ID).then(response => { this.form = response.data; this.open = true; @@ -323,7 +306,7 @@ export default { }, handlePrint() { // 获取选中数据 - const selectedData = this.bpprocureList.filter(item => this.ids.includes(item.ID)); + const selectedData = this.bpprocureList.filter(item => this.ids.includes(item.id)); if (selectedData.length === 0) { this.$message.warning("请先选择要打印的记录"); return; @@ -398,9 +381,9 @@ export default { /** 删除按钮操作 */ handleDelete(row) { - const IDs = row.ID || this.ids; + const IDs = row.id || this.ids; this.$modal.confirm('是否确认删除白坯原材料采购单编号为"' + IDs + '"的数据项?').then(function() { - return delBpprocure(IDs); + return delBpprocure(JSON.stringify(IDs)); }).then(() => { this.getList(); this.$modal.msgSuccess("删除成功");