比赛场开赛时间判断

This commit is contained in:
sk 2024-06-19 21:02:00 +08:00
commit 56fb4612c7
1 changed files with 3 additions and 1 deletions

View File

@ -1397,7 +1397,6 @@ func (this *Tournament) GetSCTMInfosPack(platform, channelName string) *tourname
if info.MatchType == MatchTypeChampion {
week := this.getWeekDay()
// 重复时间段比赛时间
for _, v := range info.MatchTimeWeek {
if v == int32(week) {
if info.MatchTimeStamp != nil && len(info.MatchTimeStamp) > 0 {
@ -1407,6 +1406,9 @@ func (this *Tournament) GetSCTMInfosPack(platform, channelName string) *tourname
}
}
}
if len(tMInfo.MatchTimeStamp) == 0 {
tMInfo.MatchTimeStamp = []int64{time.Now().AddDate(0, 0, 2).Unix(), time.Now().AddDate(0, 0, 3).Unix()}
}
} else {
if info.MatchTimeStamp != nil && len(info.MatchTimeStamp) > 0 {
for _, stamp := range info.MatchTimeStamp {