let jsonobject:Record<string,Object> = JSON.parse(JSON.stringify(res)) as Record<string,Object>;
Object.keys(jsonobject).forEach(key => {
if (key != undefined && key === 'ad_4'){
let ob4: CarouselInfo1[] = res[key] as CarouselInfo1[];
for (let index = 0; index < ob4.length; index++) {
this.rechargeCarouseInfo.push(ob4[index])
}
}
});
参考以下代码: