|
@@ -207,7 +207,8 @@ func (query *SeoBiddingQuery) GetDataPageList(ctx context.Context, pageNum, page
|
|
|
if i == pageNum {
|
|
|
res = pageTmp
|
|
|
}
|
|
|
- if err := g.Redis().SetEX(ctx, query.getDataPageListCacheKey(i, pageSize, maxTotal, flag), pageTmp, g.Cfg().MustGet(ctx, "listPageSetting.cacheTime.STypePageHandler", consts.SettingBidCacheTime).Int64()); err != nil {
|
|
|
+ fmt.Println(query.getDataPageListCacheKey(i, pageSize, maxTotal, flag), consts.GetListCacheTime(ctx, flag))
|
|
|
+ if err := g.Redis().SetEX(ctx, query.getDataPageListCacheKey(i, pageSize, maxTotal, flag), pageTmp, consts.GetListCacheTime(ctx, flag)); err != nil {
|
|
|
g.Log().Errorf(ctx, "第%d页数据 存储redis err:%v", err)
|
|
|
}
|
|
|
}
|
|
@@ -247,7 +248,8 @@ func (query *SeoBiddingQuery) GetOnceData(ctx context.Context, total int, flag s
|
|
|
if len(res) > total {
|
|
|
res = res[:total]
|
|
|
}
|
|
|
- if err := g.Redis().SetEX(ctx, cacheKey, res, g.Cfg().MustGet(ctx, "listPageSetting.cacheTime.STypePageHandler", consts.SettingBidCacheTime).Int64()); err != nil {
|
|
|
+ fmt.Println(cacheKey, consts.GetListCacheTime(ctx, flag))
|
|
|
+ if err := g.Redis().SetEX(ctx, cacheKey, res, consts.GetListCacheTime(ctx, flag)); err != nil {
|
|
|
g.Log().Errorf(ctx, "GetOnceData 存储redis err:%v", err)
|
|
|
}
|
|
|
} else {
|