diff --git a/src/api/wmsManagement/wmOneTimeInventory.js b/src/api/wmsManagement/wmOneTimeInventory.js index 75d9928..26e2a22 100644 --- a/src/api/wmsManagement/wmOneTimeInventory.js +++ b/src/api/wmsManagement/wmOneTimeInventory.js @@ -125,7 +125,7 @@ export function getPartNumber() { */ export function generateWmOneTimeRecord(data) { return request({ - url: '/mes/wm/WmPolishRecord/GetWmOneTimeRecordByDate', + url: '/mes/wm/WmOneTimeRecord/GenerateWmOneTimeRecord', method: 'post', data: data, }) diff --git a/src/views/wmsManagement/WmOneTimeQualifiedProduct/index.vue b/src/views/wmsManagement/WmOneTimeQualifiedProduct/index.vue index a908ecc..afa4711 100644 --- a/src/views/wmsManagement/WmOneTimeQualifiedProduct/index.vue +++ b/src/views/wmsManagement/WmOneTimeQualifiedProduct/index.vue @@ -51,8 +51,10 @@
- 当前抛光品总数:{{ RealQuantitySum }} + 当前一次合格品总数:{{ RealQuantitySum }} 上次导入盘点总数:{{ StocktakingTotal }} + 上次导入盘点日期:{{ MinStocktakingTime }} + 当前查询盘点零件数:{{ QuantitySum }}
@@ -346,6 +348,7 @@ export default { pageNum: 1, pageSize: 10, fkInventoryId: '', + partnumber: '', status: 1, changeType: -1, sort: 'updatedTime', @@ -375,6 +378,7 @@ export default { StocktakingTotal: 0, QuantitySum: 0, RealQuantitySum: 0, + MinStocktakingTime: '', } }, computed: { @@ -404,6 +408,7 @@ export default { this.StocktakingTotal = res.data.stocktakingTotal this.QuantitySum = res.data.quantitySum this.RealQuantitySum = res.data.realQuantitySum + this.MinStocktakingTime = res.data.minStocktakingTime this.loading = false } }) @@ -538,6 +543,7 @@ export default { this.RecordTitle = `零件号:${row.partnumber} 仓库操作记录` this.RecordOpen = true this.RecordQueryParams.fkInventoryId = row.id + this.RecordQueryParams.partnumber = row.partnumber }, // 详情 RecordOpened() { @@ -664,10 +670,11 @@ export default { }, handleRecordSync(actionType = 1) { let partnumber = '' + let startTime = this.$dayjs(this.MinStocktakingTime) // 1-全部 2-指定零件同步 let params = { actionType, - startTime: this.$dayjs().startOf('month').format('YYYY-MM-DD HH:mm:ss'), + startTime, endTime: this.$dayjs().endOf('month').format('YYYY-MM-DD HH:mm:ss'), } if (actionType === 2) { @@ -675,11 +682,12 @@ export default { } // 执行同步操作 generateWmOneTimeRecord(params).then((res) => { - if (res.code === 200) { + if (res.code === 200 && res.data > 0) { this.msgSuccess('同步成功') this.getRecordList() + this.getList() } else { - this.msgError(res.msg) + this.msgError('同步异常') } }) }, diff --git a/src/views/wmsManagement/WmPolishInventory/index.vue b/src/views/wmsManagement/WmPolishInventory/index.vue index 75c4b77..b2d77f2 100644 --- a/src/views/wmsManagement/WmPolishInventory/index.vue +++ b/src/views/wmsManagement/WmPolishInventory/index.vue @@ -53,6 +53,7 @@ 当前抛光品总数:{{ RealQuantitySum }} 上次导入盘点总数:{{ StocktakingTotal }} 上次导入盘点日期:{{ MinStocktakingTime }} + 当前查询盘点零件数:{{ QuantitySum }} @@ -672,10 +673,11 @@ export default { }, handleRecordSync(actionType = 1) { let partnumber = '' + let startTime = this.$dayjs(this.MinStocktakingTime) // 1-全部 2-指定零件同步 let params = { actionType, - startTime: this.$dayjs().startOf('month').format('YYYY-MM-DD HH:mm:ss'), + startTime, endTime: this.$dayjs().endOf('month').format('YYYY-MM-DD HH:mm:ss'), } if (actionType === 2) { @@ -683,11 +685,12 @@ export default { } // 执行同步操作 generateWmPolishRecord(params).then((res) => { - if (res.code === 200) { + if (res.code === 200 && res.data > 0) { this.msgSuccess('同步成功') this.getRecordList() + this.getList() } else { - this.msgError(res.msg) + this.msgError('同步异常') } }) },