Browse Source

数据初始化

intex
zhang_li 2 days ago
parent
commit
c96b458756
  1. 39
      src/common/detail.js

39
src/common/detail.js

@ -45,43 +45,26 @@ export function getTreeDataSource(dataList) {
} }
export function getThreeDataSource(data) { export function getThreeDataSource(data) {
let items = [] let items = []
// let obj ={ let obj ={
// ...data.subList[0] ...data.subList[0]
// } }
// console.log(12) console.log(12)
// data.subList.forEach((item)=>{
// item.threeList = [{
// fromLocationCode:item.fromLocationCode,
// batch:item.batch,
// handleQty:0,
// qty:item.qty,
// inventoryStatus:item.inventoryStatus,
// toLocationCode:item.toLocationCode,
// }]
// item.packList=[{
// scaned : false,
// scanDate: new Date()
// }]
// })
// obj.subList = data.subList
// items.push(obj)
// return items;
data.subList.forEach((item)=>{ data.subList.forEach((item)=>{
item.subList = [{ item.threeList = [{
fromLocationCode:item.fromLocationCode, fromLocationCode:item.fromLocationCode,
batch:item.batch, batch:item.batch,
handleQty:0, handleQty:0,
qty:item.qty, qty:item.qty,
inventoryStatus:item.inventoryStatus, inventoryStatus:item.inventoryStatus,
toLocationCode:item.toLocationCode, toLocationCode:item.toLocationCode,
// packList:[{
// scaned : false,
// scanDate: new Date()
// }]
}] }]
item.packList=[{
scaned : false,
scanDate: new Date()
}]
}) })
items = data.subList obj.subList = data.subList
items.push(obj)
return items; return items;
} }

Loading…
Cancel
Save