From 2ef69152850b86844d1a77614461a7c6a2ea4b65 Mon Sep 17 00:00:00 2001 From: chenjianan Date: Fri, 8 Mar 2019 11:28:34 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=87=E8=B4=AD=E5=85=A5=E5=BA=93=E5=8D=95bu?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/Inventory/InboundCard.js | 4 +- src/views/Inventory/InboundCard/index.vue | 113 +++++++++++++--------- 2 files changed, 67 insertions(+), 50 deletions(-) diff --git a/src/api/Inventory/InboundCard.js b/src/api/Inventory/InboundCard.js index 616a0857..04c53795 100644 --- a/src/api/Inventory/InboundCard.js +++ b/src/api/Inventory/InboundCard.js @@ -33,14 +33,14 @@ export function searchInventory() { }) } // 入库记录查询 -export function searchInbound(data1, data2, data3) { +export function searchInbound(...data) { return request({ url: '', method: 'post', data: { type: '1', name: '库存管理_入库记录_采购部查询', - param: '采购合同流水号=' + data1 + '&到货时间=' + data2 + '&仓库流水号=' + data3 + param: `采购合同流水号_check=${data[0]}&采购合同流水号=${data[1]}&到货时间_check=${data[2]}&到货开始时间=${data[3]}&到货结束时间=${data[4]}&仓库流水号_check=${data[5]}&仓库流水号=${data[6]}` } }) } diff --git a/src/views/Inventory/InboundCard/index.vue b/src/views/Inventory/InboundCard/index.vue index b812aef5..fbff44e5 100644 --- a/src/views/Inventory/InboundCard/index.vue +++ b/src/views/Inventory/InboundCard/index.vue @@ -11,14 +11,21 @@ :label="item.label" :value="item.value"/> - 入库日期 + 到货时间 + placeholder="选择开始日期"/> ~ + 仓库: - + + + + - + - + - + - + - + - + @@ -164,35 +176,25 @@ + - 入库单编号 + 入库单编号: 查询 创建 选入 + - - - + + @@ -200,7 +202,7 @@ {{ scope.row.仓库名称 }} - + @@ -212,7 +214,7 @@ @@ -220,7 +222,7 @@ {{ scope.row.业务号 }} - + @@ -230,17 +232,17 @@ {{ scope.row.姓名 }} - + - + - + @@ -268,16 +270,7 @@ @size-change="handleSizeChange2" @current-change="handleCurrentChange2"/> - + - + - + - + - + +
@@ -433,6 +427,7 @@ 打印
+ @@ -526,6 +521,7 @@ 确定 + @@ -636,6 +632,8 @@ export default { ShopContractValue: '', // 车间采购合同流水号 Inventory: [], InventoryValue: '', + InboundStartDate: '', + InboundEndDate: '', InboundDate: '', listLoading: '', tableData: [], @@ -701,6 +699,7 @@ export default { created() { this.searchContractData() this.searchInventoryData() + this.searchInboundCard1() }, methods: { searchContractData() { // 查询合同 @@ -743,7 +742,11 @@ export default { searchPartinfo() { this.tableData = [] this.listLoading = true - searchInbound(this.ContractValue, this.InboundDate, this.InventoryValue).then(response => { + let check1, check2, check3 + this.ContractValue ? check1 = 1 : check1 = 0 + this.InboundStartDate && this.InboundEndDate ? check2 = 1 : (check2 = 0, this.InboundStartDate = null, this.InboundEndDate = null) + this.InventoryValue ? check3 = 1 : check3 = 0 + searchInbound(check1, this.ContractValue, check2, this.InboundStartDate, this.InboundEndDate, check3, this.InventoryValue).then(response => { for (let i = 0; i < response.data.length; i++) { if (response.data[i].组件零件流水号 === 0) { response.data[i].物料名称 = response.data[i].零件名称 @@ -786,6 +789,7 @@ export default { addInboundCard(this.form.inboundDay, this.form.house, this.form.contract, this.form.arrive, this.form.affairPeople, this.form.affair, this.form.arriveDay, this.form.affirType, this.form.purchaseType, this.form.inboundType, this.form.note).then(response => { if (response.data[0].result === '1') { this.$message.success('增加成功') + this.searchInboundCard1() this.dialogVisible1 = false } else { this.$message.error('增加失败') @@ -867,6 +871,7 @@ export default { editInboundCard(this.DetailNumber, this.form.inboundDay, this.form.house, this.form.contract, this.form.arrive, this.form.affairPeople, this.form.affair, this.form.arriveDay, this.form.affirType, this.form.purchaseType, this.form.inboundType, this.form.note).then(response => { if (response.data[0].result === '1') { this.$message.success('修改成功') + this.searchInboundCard1() this.dialogVisible2 = false } else { this.$message.error('修改失败') @@ -1035,6 +1040,18 @@ export default {