...
|
...
|
@@ -28,7 +28,7 @@ type RankPeriodEndTime struct { |
|
|
func AutoCreateRankPeriod() error {
|
|
|
log.Info("计划任务:【自动创建赛季】")
|
|
|
//获取需要执行自动创建的榜单记录
|
|
|
sql1 := `ELECT a.id AS rank_type_id,a.auto_period,UNIX_TIMESTAMP(a.create_at) AS create_time
|
|
|
sql1 := `SELECT a.id AS rank_type_id,a.auto_period,UNIX_TIMESTAMP(a.create_at) AS create_time
|
|
|
,a.company_id
|
|
|
FROM rank_type AS a
|
|
|
JOIN company AS b ON a.company_id=b.id AND b.enable=1 AND b.delete_at=0
|
...
|
...
|
@@ -98,6 +98,7 @@ LOOP0: |
|
|
CreateAt: nowTime,
|
|
|
UpdateAt: nowTime,
|
|
|
Status: models.RANKPERIOD_STATUS_NOT,
|
|
|
IsAuto: 1,
|
|
|
}
|
|
|
if t, ok := rankPeriodMap[v.RankTypeId]; ok {
|
|
|
s := time.Unix(t, 0).Format("2006-01-02")
|
...
|
...
|
|