这样的数组:
let a=this.moneyApplyInfo.amount;
let b=this.moneyApplyInfo.companyNames;
this.companyMoneyList=a.map((o,i)=>{
return [o,b[i]]
});
后台打印出的合成后的数据:
如果是多个数组:
let a=['公司A','公司B','公司C']
let b=['1100','2200','3300']
let c=['张三','李四','王五']
let d = a.map((o,i)=>{
return [o,b[i],c[i]]
})
返回数据:d=[ ['公司A','1100','张三'],['公司B','2200','李四'],['公司C','3300','王五'] ]