//去重 + 获取天数
let
arr = [];
days.forEach(item=>{
let
arrItem = arr.find(x => x.price === item.price);
if
(!arrItem){
arr.push({ price:item.price,num:
1
});
}
else
{
arrItem.num++;
}
});