diff --git a/src/pages/pointPutawayJob/index.vue b/src/pages/pointPutawayJob/index.vue index dd21a660..f3e684ca 100644 --- a/src/pages/pointPutawayJob/index.vue +++ b/src/pages/pointPutawayJob/index.vue @@ -280,24 +280,28 @@ export default { }, async onShow() { // 获取上架指引单 - await getJimuPutawayJobDetail({ - masterIds: this.data.ids - }).then(res => { - this.data.sublist = res.data - this.getTableSubList() - }) + if(this.data.ids){ + await getJimuPutawayJobDetail({ + masterIds: this.data.ids + }).then(res => { + this.data.sublist = res.data + this.getTableSubList() + }) + } // 获取采购收货指引单 - await queryInspectionFreeFlag({ - number: this.number - }).then(async res1 => { - this.data1 = res1.data - this.data1.inspectDTOList = this.data1.inspectDTOList.filter(item=>item.sampleQty>0) - // this.data1.inspectDTOList=[] - if(this.data1&&this.data1.inspectDTOList&&this.data1.inspectDTOList.length == 0){ - this.tabIndex =2 - } - this.getTableInspectDTOList() - }) + if(this.number){ + await queryInspectionFreeFlag({ + number: this.number + }).then(async res1 => { + this.data1 = res1.data + this.data1.inspectDTOList = this.data1.inspectDTOList.filter(item=>item.sampleQty>0) + // this.data1.inspectDTOList=[] + if(this.data1&&this.data1.inspectDTOList&&this.data1.inspectDTOList.length == 0){ + this.tabIndex =2 + } + this.getTableInspectDTOList() + }) + } this.getPointPutawayJobHtml() this.getPurchaseReceiptJobHtml() },