|
@@ -811,7 +811,7 @@ func GetChartPredictEdbInfoDataListByRuleSeason(edbInfoId int, yearsList []int,
|
|
|
var isFindHistoryCurrent, isFindHistoryLast bool //是否找到前几年的数据
|
|
|
|
|
|
//前几年当日的日期
|
|
|
- tmpHistoryCurrentDate := currentDate.AddDate(year-currentDate.Year(), 0, moveDay)
|
|
|
+ tmpHistoryCurrentDate := currentDate.AddDate(year-currentDate.Year(), 0, -moveDay)
|
|
|
for i := 0; i <= 35; i++ { // 前后35天找数据,找到最近的值,先向后面找,再往前面找
|
|
|
tmpDate := tmpHistoryCurrentDate.AddDate(0, 0, i)
|
|
|
if val, ok := existMap[tmpDate.Format(utils.FormatDate)]; ok {
|