diff --git a/ant-design-vue-jeecg/src/views/system/receipt/ReceiptContainerHeaderList.vue b/ant-design-vue-jeecg/src/views/system/receipt/ReceiptContainerHeaderList.vue index 1bdcd05..e014ece 100644 --- a/ant-design-vue-jeecg/src/views/system/receipt/ReceiptContainerHeaderList.vue +++ b/ant-design-vue-jeecg/src/views/system/receipt/ReceiptContainerHeaderList.vue @@ -390,39 +390,38 @@ export default { if (this.selectedRowKeys.length <= 0) { this.$message.warning('请选择一条记录!'); return; - } else { - var ids = ""; - for (var a = 0; a < this.selectedRowKeys.length; a++) { - if (this.selectionRows[a].status == 0) { - ids += this.selectedRowKeys[a] + ","; - } - } - if(ids == "") { - this.$message.warning("没有符合取消条件的组盘"); - return; + } + var ids = ""; + for (var a = 0; a < this.selectedRowKeys.length; a++) { + if (this.selectionRows[a] != null && this.selectionRows[a].status == 0) { + ids += this.selectedRowKeys[a] + ","; } - var that = this; - this.$confirm({ - title: "确认删除", - content: "是否删除选中数据?", - onOk: function () { - that.loading = true; - deleteAction(that.url.deleteBatch, {ids: ids}).then((res) => { - if (res.success) { - //重新计算分页问题 - that.reCalculatePage(that.selectedRowKeys.length) - that.$message.success(res.message); - that.loadData(); - that.onClearSelected(); - } else { - that.$message.warning(res.message); - } - }).finally(() => { - that.loading = false; - }); - } - }); } + if(ids == "") { + this.$message.warning("没有符合取消条件的记录!"); + return; + } + var that = this; + this.$confirm({ + title: "确认删除", + content: "是否删除选中数据?", + onOk: function () { + that.loading = true; + deleteAction(that.url.deleteBatch, {ids: ids}).then((res) => { + if (res.success) { + //重新计算分页问题 + that.reCalculatePage(that.selectedRowKeys.length) + that.$message.success(res.message); + that.loadData(); + that.onClearSelected(); + } else { + that.$message.warning(res.message); + } + }).finally(() => { + that.loading = false; + }); + } + }); }, loadData(arg) { if (!this.url.list) { diff --git a/ant-design-vue-jeecg/src/views/system/shipment/ShipmentContainerHeaderList.vue b/ant-design-vue-jeecg/src/views/system/shipment/ShipmentContainerHeaderList.vue index d256eaf..37bc080 100644 --- a/ant-design-vue-jeecg/src/views/system/shipment/ShipmentContainerHeaderList.vue +++ b/ant-design-vue-jeecg/src/views/system/shipment/ShipmentContainerHeaderList.vue @@ -300,68 +300,68 @@ export default { if (this.selectedRowKeys.length <= 1) { this.$message.warning('至少选择两条记录!') return - } else { - var shipmentContainerHeaderList = [] - var shipmentContainerHeader = null - for (var a = 0; a < this.selectedRowKeys.length; a++) { - if (this.selectionRows[a] != null && this.selectionRows[a].status == 0) { - if (shipmentContainerHeader == null) { - shipmentContainerHeader = this.selectionRows[a] - } - if (shipmentContainerHeader.taskType == this.selectionRows[a].taskType) { - shipmentContainerHeaderList.push(this.selectionRows[a]) - } + } + var shipmentContainerHeaderList = [] + var shipmentContainerHeader = null + for (var a = 0; a < this.selectedRowKeys.length; a++) { + if (this.selectionRows[a] != null && this.selectionRows[a].status == 0) { + if (shipmentContainerHeader == null) { + shipmentContainerHeader = this.selectionRows[a] + } + if (shipmentContainerHeader.taskType == this.selectionRows[a].taskType) { + shipmentContainerHeaderList.push(this.selectionRows[a]) } - } - if (shipmentContainerHeaderList.length > 0) { - this.$refs.modalForm2.batchEdit(shipmentContainerHeaderList) - this.$refs.modalForm2.title = '选择出库口' - } else { - this.$message.error("至少选择两条符合条件的记录!") } } + if (shipmentContainerHeaderList.length > 0) { + this.$refs.modalForm2.batchEdit(shipmentContainerHeaderList) + this.$refs.modalForm2.title = '选择出库口' + } else { + this.$message.error("至少选择两条符合条件的记录!") + } }, cancelBatchTask() { if (!this.url.deleteBatch) { - this.$message.error("请设置url.deleteBatch属性!") + this.$message.error('请设置url.deleteBatch属性!') return } if (this.selectedRowKeys.length <= 0) { - this.$message.warning('请选择一条记录!'); - return; - } else { - var ids = ""; - for (var a = 0; a < this.selectedRowKeys.length; a++) { - if (this.selectionRows[a].status == 0) { - ids += this.selectedRowKeys[a] + ","; - } - } - if(ids == "") { - this.$message.warning("没有符合取消条件的组盘"); - return; + this.$message.warning('请选择一条记录!') + return + } + var ids = '' + for (var a = 0; a < this.selectedRowKeys.length; a++) { + if (this.selectionRows[a] != null && this.selectionRows[a].status == 0) { + ids += this.selectedRowKeys[a] + ',' } - var that = this; - this.$confirm({ - title: "确认删除", - content: "是否删除选中数据?", - onOk: function () { - that.loading = true; - deleteAction(that.url.deleteBatch, {ids: ids}).then((res) => { + } + if (ids == '') { + this.$message.warning('没有符合取消条件的记录!') + return + } + var that = this + this.$confirm({ + title: '确认删除', + content: '是否删除选中数据?', + onOk: function() { + that.loading = true + deleteAction(that.url.deleteBatch, { ids: ids }) + .then(res => { if (res.success) { //重新计算分页问题 that.reCalculatePage(that.selectedRowKeys.length) - that.$message.success(res.message); - that.loadData(); - that.onClearSelected(); + that.$message.success(res.message) + that.loadData() + that.onClearSelected() } else { - that.$message.warning(res.message); + that.$message.warning(res.message) } - }).finally(() => { - that.loading = false; - }); - } - }); - } + }) + .finally(() => { + that.loading = false + }) + } + }) }, loadData(arg) { if (!this.url.list) { diff --git a/ant-design-vue-jeecg/src/views/system/task/ReceiptTaskHeaderList.vue b/ant-design-vue-jeecg/src/views/system/task/ReceiptTaskHeaderList.vue index 60eba75..f8621b0 100644 --- a/ant-design-vue-jeecg/src/views/system/task/ReceiptTaskHeaderList.vue +++ b/ant-design-vue-jeecg/src/views/system/task/ReceiptTaskHeaderList.vue @@ -85,7 +85,7 @@ <div class="table-operator"> <a-button @click="createEmptyIn()" v-has="'taskHeader:emptyIn'" type="primary">空托入库</a-button> <a-button @click="createManyEmptyIn()" v-has="'taskHeader:manyEmptyIn'" type="primary">空托组入库</a-button> - <a-button @click="openDemo()" type="primary">弹出demo</a-button> + <!-- <a-button @click="openDemo()" type="primary">弹出demo</a-button> --> </div> <!-- table区域-begin -->