From 0958e2cf34e16d43c219500b81a8ef0bc86bf55f Mon Sep 17 00:00:00 2001 From: Vergil <974548713@qq.com> Date: Wed, 25 Mar 2020 09:46:49 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=90=E7=BB=84=E9=85=8D=E5=A5=97=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/ManufacturingCenter/GroupMatching.js | 13 +++++++++ .../GroupMatching/index.vue | 29 +++++++++---------- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/src/api/ManufacturingCenter/GroupMatching.js b/src/api/ManufacturingCenter/GroupMatching.js index ec5ef062..ef1166e8 100644 --- a/src/api/ManufacturingCenter/GroupMatching.js +++ b/src/api/ManufacturingCenter/GroupMatching.js @@ -40,6 +40,19 @@ export function searchTable(check1, machine, check2, groupNum, pageCurrent, page } }) } +export function getTable(check1, machine, check2, groupNum, pageCurrent, pageSize) { + return request({ + url: '', + method: 'post', + data: { + UserID: state.state.user.id, + ModularID: router.currentRoute.path, + type: '1', + name: '车间生产管理工艺_基本件成组配套_查询数据_新', + param: '机床流水号_check=' + check1 + '=int&机床流水号=' + machine + '=int&组件流水号_check=' + check2 + '=int&组件流水号=' + groupNum + `&PageCurrent=${pageCurrent}&PageSize=${pageSize}&PageCount=1111=int=output&ItemCount=1111=int=output` + } + }) +} export function searchTable22(check1, machine, check2, groupNum, check3, year, check4, month, check5, time) { return request({ url: '', diff --git a/src/views/ManufacturingCenter/GroupMatching/index.vue b/src/views/ManufacturingCenter/GroupMatching/index.vue index 8bf4d8ef..d70fcc81 100644 --- a/src/views/ManufacturingCenter/GroupMatching/index.vue +++ b/src/views/ManufacturingCenter/GroupMatching/index.vue @@ -496,7 +496,6 @@ export default { this.Machine ? this.check1 = 1 : this.check1 = 0 this.Group ? this.check2 = 1 : this.check2 = 0 searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => { - console.log(response.data) for (let i = 0; i < response.data.result.length; i++) { if (response.data.result[i].入库时间) { response.data.result[i].入库时间 = response.data.result[i].入库时间.split(' ', 2)[0] @@ -604,16 +603,16 @@ export default { this.Machine ? this.check1 = 1 : this.check1 = 0 this.Group ? this.check2 = 1 : this.check2 = 0 searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => { - for (let i = 0; i < response.data.rows.length; i++) { - if (response.data.rows[i].入库时间 !== '') { - response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0] + for (let i = 0; i < response.data.result.length; i++) { + if (response.data.result[i].入库时间) { + response.data.result[i].入库时间 = response.data.result[i].入库时间.split(' ', 2)[0] } - if (response.data.rows[i].计划完成时间 !== '') { - response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0] + if (response.data.result[i].计划完成时间) { + response.data.result[i].计划完成时间 = response.data.result[i].计划完成时间.split(' ', 2)[0] } } - this.tableData = response.data.rows - this.total = parseInt(response.data.total) + this.tableData = response.data.result + this.total = parseInt(response.data.output[0].ItemCount) this.loading = false }) }, @@ -623,16 +622,16 @@ export default { this.Machine ? this.check1 = 1 : this.check1 = 0 this.Group ? this.check2 = 1 : this.check2 = 0 searchTable(this.check1, this.Machine, this.check2, this.Group, this.pageCurrent, this.pageSize).then(response => { - for (let i = 0; i < response.data.rows.length; i++) { - if (response.data.rows[i].入库时间 !== '') { - response.data.rows[i].入库时间 = response.data.rows[i].入库时间.split(' ', 2)[0] + for (let i = 0; i < response.data.result.length; i++) { + if (response.data.result[i].入库时间) { + response.data.result[i].入库时间 = response.data.result[i].入库时间.split(' ', 2)[0] } - if (response.data.rows[i].计划完成时间 !== '') { - response.data.rows[i].计划完成时间 = response.data.rows[i].计划完成时间.split(' ', 2)[0] + if (response.data.result[i].计划完成时间) { + response.data.result[i].计划完成时间 = response.data.result[i].计划完成时间.split(' ', 2)[0] } } - this.tableData = response.data.rows - this.total = parseInt(response.data.total) + this.tableData = response.data.result + this.total = parseInt(response.data.output[0].ItemCount) this.loading = false }) },