publicing(postSettle,data)
.then((res)=>{
console.log(res)
this.extraUserInfo = res.data.data.extraData.userInfo
this.goodsData = res.data.data.data
let new_arr = this.goodsData.map(obj => {return obj.id})//提取数组里面的每一项里面的id
this.ids2 = new_arr
//拼接字符串id
let idList = "";
for(let index in this.ids2){
idList = idList + this.ids2[index] + ",";
}
//去掉双引号
console.log("idList====",idList)
//去除idList最后一个逗号
idList = idList.substring(0,idList.length - 1);
console.log("idList去除逗号后====",idList)
log(idList)
})
.catch((err)=>{
console.log(err)
})
网友评论