|
@ -232,8 +232,9 @@ const searchTableSuccess = async (formField, searchField, val, formRef, type, ro |
|
|
nextTick(async () => { |
|
|
nextTick(async () => { |
|
|
if (type == 'tableForm') { |
|
|
if (type == 'tableForm') { |
|
|
// 明细查询页赋值 |
|
|
// 明细查询页赋值 |
|
|
row[formField] = val[0][searchField] |
|
|
|
|
|
if (formField == 'purchaseReceiptRecordNumber') { |
|
|
if (formField == 'purchaseReceiptRecordNumber') { |
|
|
|
|
|
row[formField] = val[0][searchField] |
|
|
//搜索记录单号--回显数据 |
|
|
//搜索记录单号--回显数据 |
|
|
row['supplierCode'] = val[0]['supplierCode'] |
|
|
row['supplierCode'] = val[0]['supplierCode'] |
|
|
row['poNumber'] = val[0]['poNumber'] |
|
|
row['poNumber'] = val[0]['poNumber'] |
|
@ -271,6 +272,7 @@ const searchTableSuccess = async (formField, searchField, val, formRef, type, ro |
|
|
row['amount'] = val[0]['amount'] |
|
|
row['amount'] = val[0]['amount'] |
|
|
row['projectCode'] = val[0]['projectCode'] |
|
|
row['projectCode'] = val[0]['projectCode'] |
|
|
} else if (formField == 'itemCode') { |
|
|
} else if (formField == 'itemCode') { |
|
|
|
|
|
row[formField] = val[0][searchField] |
|
|
row['batch'] = val[0]['toBatch'] |
|
|
row['batch'] = val[0]['toBatch'] |
|
|
row['containerNumber'] = val[0]['toContainerNumber'] |
|
|
row['containerNumber'] = val[0]['toContainerNumber'] |
|
|
row['containerNumber'] = val[0]['containerNumber'] |
|
|
row['containerNumber'] = val[0]['containerNumber'] |
|
@ -278,6 +280,7 @@ const searchTableSuccess = async (formField, searchField, val, formRef, type, ro |
|
|
// row['fromLocationCode'] = val[0]['fromLocationCode'] |
|
|
// row['fromLocationCode'] = val[0]['fromLocationCode'] |
|
|
row['toLocationCode'] = val[0]['toLocationCode'] |
|
|
row['toLocationCode'] = val[0]['toLocationCode'] |
|
|
} else if (formField == 'fromLocationCode') { |
|
|
} else if (formField == 'fromLocationCode') { |
|
|
|
|
|
row[formField] = val[0][searchField] |
|
|
// let params = { |
|
|
// let params = { |
|
|
// itemCode: row.itemCode, |
|
|
// itemCode: row.itemCode, |
|
|
// batch: row.batch, |
|
|
// batch: row.batch, |
|
@ -287,7 +290,21 @@ const searchTableSuccess = async (formField, searchField, val, formRef, type, ro |
|
|
// console.log('23423423',aa); |
|
|
// console.log('23423423',aa); |
|
|
// row['inventoryBalance'] = aa//库存余额 |
|
|
// row['inventoryBalance'] = aa//库存余额 |
|
|
} else if (formField == 'packingNumber') { |
|
|
} else if (formField == 'packingNumber') { |
|
|
row['inventoryBalance'] = val[0]['qty'] //库存余额 |
|
|
// row[formField] = val[0][searchField] |
|
|
|
|
|
val.forEach((item,index)=>{ |
|
|
|
|
|
if(index==0){ |
|
|
|
|
|
row[formField] = item[searchField] |
|
|
|
|
|
row['inventoryBalance'] = item['qty'] //库存余额 |
|
|
|
|
|
}else{ |
|
|
|
|
|
let newRow = {...row} |
|
|
|
|
|
newRow[formField] = item[searchField] |
|
|
|
|
|
row['inventoryBalance'] = item['qty'] //库存余额 |
|
|
|
|
|
tableData.value.push(newRow) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
// row['inventoryBalance'] = val[0]['qty'] //库存余额 |
|
|
|
|
|
}else{ |
|
|
|
|
|
row[formField] = val[0][searchField] |
|
|
} |
|
|
} |
|
|
} else { |
|
|
} else { |
|
|
const setV = {} |
|
|
const setV = {} |
|
|