Commit b105c727 authored by 张海景's avatar 张海景

update:修改申请单的任务单

parent 24cfa444
...@@ -109,7 +109,9 @@ export default { ...@@ -109,7 +109,9 @@ export default {
form: {}, form: {},
// 表单校验 // 表单校验
rules: { rules: {
} },
addList: [],
detailList: []
}; };
}, },
watch: { watch: {
...@@ -127,7 +129,7 @@ export default { ...@@ -127,7 +129,7 @@ export default {
methods: { methods: {
onItemSelect(list){ onItemSelect(list){
// console.log(list, 'list') // console.log(list, 'list')
const datas = list.map(item => { this.addList = list.map(item => {
return { return {
itemId:item.itemId, itemId:item.itemId,
itemName:item.itemName, itemName:item.itemName,
...@@ -135,7 +137,7 @@ export default { ...@@ -135,7 +137,7 @@ export default {
nextMaintenPeriod: this.$attrs.quantity nextMaintenPeriod: this.$attrs.quantity
} }
}) })
this.tmToolRequestItemList = this.tmToolRequestItemList.concat(datas) this.tmToolRequestItemList = this.detailList.concat(this.addList)
this.$emit('sum') this.$emit('sum')
}, },
/** 查询刀模板物料申请单列表 */ /** 查询刀模板物料申请单列表 */
...@@ -154,13 +156,19 @@ export default { ...@@ -154,13 +156,19 @@ export default {
this.queryParams.taskId = this.$attrs.taskId; this.queryParams.taskId = this.$attrs.taskId;
this.queryParams.pageSize = 10000; this.queryParams.pageSize = 10000;
getTaskIdMaxProcessTool(this.queryParams).then(response => { getTaskIdMaxProcessTool(this.queryParams).then(response => {
const datas = response.data.map(item => { this.detailList = response.data.map(item => {
return { return {
...item, ...item,
allQuantity: item.AllQuantity allQuantity: item.AllQuantity
} }
}); });
this.tmToolRequestItemList = this.tmToolRequestItemList.concat(datas) this.addList = this.addList.map(item => {
return {
...item,
nextMaintenPeriod: this.$attrs.quantity
}
})
this.tmToolRequestItemList = this.detailList.concat(this.addList)
// this.total = response.total; // this.total = response.total;
this.loading = false; this.loading = false;
this.$emit('sum') this.$emit('sum')
......
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