作者 陈志颖

test:年榜管理

@@ -463,7 +463,7 @@ func (statisticsService *StatisticsService) ContributionsWealthRanking(contribut @@ -463,7 +463,7 @@ func (statisticsService *StatisticsService) ContributionsWealthRanking(contribut
463 contributionsWealthRankingQuery.StartTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local) 463 contributionsWealthRankingQuery.StartTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local)
464 contributionsWealthRankingQuery.EndTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local) 464 contributionsWealthRankingQuery.EndTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local)
465 } 465 }
466 - } else { // 配置了多个年榜,判断当前时间是否在榜单里 466 + } else if len(listIntervals) > 1 { // 配置了多个年榜,判断当前时间是否在榜单里
467 //currentTime := time.Now().Local() 467 //currentTime := time.Now().Local()
468 //for _, listInterval := range listIntervals { 468 //for _, listInterval := range listIntervals {
469 // if currentTime.After(listInterval.IntervalStartTime.Local()) && currentTime.Before(listInterval.IntervalEndTime.Local()) || currentTime.Equal(listInterval.IntervalStartTime.Local()) || currentTime.Equal(listInterval.IntervalEndTime.Local()) { // 当前时间在榜单内 469 // if currentTime.After(listInterval.IntervalStartTime.Local()) && currentTime.Before(listInterval.IntervalEndTime.Local()) || currentTime.Equal(listInterval.IntervalStartTime.Local()) || currentTime.Equal(listInterval.IntervalEndTime.Local()) { // 当前时间在榜单内
@@ -488,6 +488,9 @@ func (statisticsService *StatisticsService) ContributionsWealthRanking(contribut @@ -488,6 +488,9 @@ func (statisticsService *StatisticsService) ContributionsWealthRanking(contribut
488 break 488 break
489 } 489 }
490 } 490 }
  491 + } else {
  492 + contributionsWealthRankingQuery.StartTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local)
  493 + contributionsWealthRankingQuery.EndTime = time.Date(0001, 01, 02, 0, 0, 0, 0, time.Local)
491 } 494 }
492 } 495 }
493 } 496 }