func GetDays(start, end int64) (timeSilce []string) {
startTime := time.Unix(start, 0)
endTime := time.Unix(end, 0)
sub := int(endTime.Sub(startTime).Hours())
days := sub / 24
if (sub % 24) > 0 {
days = days + 1
}
for i := days; i > 0; i-- {
timeSilce = append(timeSilce, time.Now().AddDate(0, 0, -i).Format("2006-01-02"))
}
return
}
03-01
11-30
1519
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
09-20
4441
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
06-13
2686
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)