|
@@ -30,6 +30,7 @@ type NewIndex struct {
|
|
|
}
|
|
|
|
|
|
var (
|
|
|
+ RedisTimeout = 2 * 3600
|
|
|
routerRelayMap map[string]map[bool]string
|
|
|
BiddingTypeUrl = map[int]string{
|
|
|
1: "/list/stype/ZBYG.html",
|
|
@@ -317,7 +318,7 @@ func GetRecommendBidZone(typ int, pageSize int) (list []map[string]interface{},
|
|
|
}
|
|
|
finalArr := FillingBiddingBaseFields(gctx.New(), queryRes.List(), typs)
|
|
|
if finalArr != nil && len(finalArr) > 0 {
|
|
|
- redis.Put(RedisNameNew, rediskey, finalArr, 24*3600)
|
|
|
+ redis.Put(RedisNameNew, rediskey, finalArr, RedisTimeout)
|
|
|
}
|
|
|
return finalArr, typs
|
|
|
}
|
|
@@ -424,7 +425,7 @@ func GetIndexProjectListRedis(typ, pageSize int) (data []map[string]interface{},
|
|
|
}
|
|
|
data, _ = GetIndexProjectList(typ, pageSize, []map[string]interface{}{})
|
|
|
if data != nil && len(data) > 0 {
|
|
|
- redis.Put(RedisNameNew, redidKey, data, 24*3600+rand.Intn(100))
|
|
|
+ redis.Put(RedisNameNew, redidKey, data, RedisTimeout+rand.Intn(100))
|
|
|
}
|
|
|
return data, types
|
|
|
}
|
|
@@ -454,7 +455,7 @@ func GetIndexRecommendProjectList(typ, pageSize int) (data []map[string]interfac
|
|
|
data = append(data, v)
|
|
|
}
|
|
|
if data != nil && len(data) > 0 {
|
|
|
- redis.Put(RedisNameNew, redidKey, data, 24*3600+rand.Intn(100))
|
|
|
+ redis.Put(RedisNameNew, redidKey, data, RedisTimeout+rand.Intn(100))
|
|
|
}
|
|
|
return data, types
|
|
|
}
|
|
@@ -499,7 +500,7 @@ func GetBidInfoPublishEnt() (res [][]map[string]interface{}) {
|
|
|
res = append(res, once)
|
|
|
}
|
|
|
}
|
|
|
- redis.Put(RedisNameNew, "pcIndexBidInfoGoodPublishEnt", res, 24*3600)
|
|
|
+ redis.Put(RedisNameNew, "pcIndexBidInfoGoodPublishEnt", res, RedisTimeout+rand.Intn(100))
|
|
|
}
|
|
|
}
|
|
|
return res
|
|
@@ -517,7 +518,7 @@ func GetImportBidding() []*hotKeyWord {
|
|
|
randomNumber := rand.Intn(len(subjectMatter) - 30)
|
|
|
res := subjectMatter[randomNumber : randomNumber+30]
|
|
|
if len(res) > 0 {
|
|
|
- redis.Put(RedisNameNew, "pcIndexImportBidding", res, 24*3600)
|
|
|
+ redis.Put(RedisNameNew, "pcIndexImportBidding", res, RedisTimeout+rand.Intn(100))
|
|
|
}
|
|
|
return res
|
|
|
}
|