Commit e6c5b21f authored by jingnan's avatar jingnan 👀

ERP相关_领用出库确认增加响应及打印标签

parent 6ef3b623
......@@ -11,6 +11,15 @@
ref="itemCom"
:lay-config="{ typeName: 'OutStorageMaterialUseItem', layKey: 'defaultResult'}"
table-height="auto"
:basic-data=" { selectData,selectionRowsItem,...currentLeftData }"
@selectionChange="selectionChangeItem"
/>
<dee-as-com
ref="responseTable"
:lay-config="{ typeName: 'JobResponseOutStorageMaterialUse', layKey: 'defaultResult'}"
table-height="auto"
:basic-data=" { selectData,selectionRowsRes,...currentLeftData }"
@selectionChangeRes="selectionChangeRes"
/>
</div>
</template>
......@@ -32,8 +41,8 @@ export default {
data() {
return {
selectionRows: [],
selectionItemRows: [],
selectionJobResRows: []
selectionRowsItem: [],
selectionRowsRes: []
}
},
computed: {},
......@@ -48,8 +57,13 @@ export default {
const requestIds = val && val.map(item => item.id)
this.$refs.itemCom && this.$refs.itemCom.$refs.asCom.getData(requestIds)
},
selectionChange_jobRes(val) {
this.selectionJobResRows = val
selectionChangeItem(val) {
this.selectionRowsItem = val
const itemIds = val && val.map(item => item.id) || []
this.$refs.responseTable && this.$refs.responseTable.$refs.asCom.getData(itemIds)
},
selectionChangeRes(val) {
this.selectionRowsRes = val
},
init(checkList) {
const aoIds = checkList && checkList.map(item => item.id)
......@@ -63,10 +77,13 @@ export default {
setTimeout(() => {
const requestComRef = this.$refs.requestCom && (this.$refs.requestCom.$refs.asCom) || null
const itemComRef = this.$refs.itemCom && (this.$refs.itemCom.$refs.asCom) || {}
const responseRef = this.$refs.responseTable && (this.$refs.responseTable.$refs.asCom) || {}
requestComRef && (requestComRef.pagination.total = 0)
itemComRef && (itemComRef.pagination.total = 0)
responseRef && (responseRef.pagination.total = 0)
requestComRef && (requestComRef.showData = [])
itemComRef && (itemComRef.showData = [])
responseRef && (responseRef.showData = [])
}, 800)
}
}
......
......@@ -103,6 +103,8 @@ export default {
this.printFlowLable(selection)
} else if (selectSubTypeName === 'Inventory') { // 打印移库标签
this.printMoveLibraryLabel(selection)
} else if (selectSubTypeName === 'JobResponseOutStorageMaterialUse') { // 打印材料领用出库标签
this.printJobResMaterialUseLabel(selection)
} else if (selectSubTypeName === 'JobResponseOutStorageMatch' || selectSubTypeName === 'JobResponseOutStorageOut' || selectSubTypeName === 'JobResponseOutStorageUse') { // 批量签审_配套出库响应打印标签||批量签审_供外出库响应打印标签||批量签审_领用出库响应打印标签
this.printBatchSignMatchJob(selection)
} else if (selectSubTypeName.includes('OutStorage')) { // 打印出库标签
......@@ -400,6 +402,34 @@ export default {
})
this.print()
},
printJobResMaterialUseLabel(selection) {
this.config.prints = []
selection.forEach((row) => {
this.config = Object.assign({}, this.config, {
visible: true
})
const responseInventory = row.erpInventory || {}
this.config.prints.push({
text: row.id || row.id,
propertys: [
{ label: '编码', value: responseInventory.extMaterial.resCode },
{ label: '名称', value: responseInventory.extMaterial.resName },
{ label: '型号/牌号/件号', value: responseInventory.extMaterial.modelNo },
{ label: '规格', value: responseInventory.extMaterial.spec },
{ label: '批号', value: responseInventory.batchNumber },
{ label: '系列号/序列号', value: responseInventory.serialNo },
{ label: '机型', value: responseInventory.airModel },
{ label: '出库数量', value: row.allocatedAmount || '' },
{ label: '验收单号', value: responseInventory.testNo },
{ label: '贮存期', value: responseInventory.qualityPeriod && responseInventory.qualityPeriod.replace(' 00:00:00', '') },
{ label: '库位号', value: responseInventory.workunit || '' },
{ label: 'AO号', value: responseInventory.erpOutRequest && responseInventory.erpOutRequest.aoPlan || '' },
{ label: '备注', value: row.remark || '' }
]
})
})
this.print()
},
printOutStorageLabel(selection) {
this.config.prints = []
selection.forEach((row) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment