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("删除成功");