|
@@ -129,11 +129,6 @@ func (m *MatchJob) OnceBiddingBatch(batchIndex int, start int64, prevPublishtime
|
|
|
if util.ObjToString(temp["area"]) == "A" {
|
|
|
temp["area"] = "全国"
|
|
|
}
|
|
|
- if util.ObjToString(temp["detail"]) == "" {
|
|
|
- if repl, err := client.GetBidDetailByRpc(Config.OssAddr, &entity.Args{"detail", _id}); err != nil {
|
|
|
- temp["detail"] = repl.Data
|
|
|
- }
|
|
|
- }
|
|
|
res = append(res, temp)
|
|
|
temp = make(map[string]interface{})
|
|
|
index++
|
|
@@ -141,6 +136,14 @@ func (m *MatchJob) OnceBiddingBatch(batchIndex int, start int64, prevPublishtime
|
|
|
logger.Info("第", batchIndex, "批", "加载", DbConf.Mongodb.Bidding.Collection, "数据:", index)
|
|
|
}
|
|
|
}
|
|
|
+ for _, temp := range res {
|
|
|
+ if util.ObjToString(temp["detail"]) != "" {
|
|
|
+ continue
|
|
|
+ }
|
|
|
+ if repl, err := client.GetBidDetailByRpc(Config.OssAddr, &entity.Args{"detail", util.ObjToString(temp["_id"])}); err != nil {
|
|
|
+ temp["detail"] = repl.Data
|
|
|
+ }
|
|
|
+ }
|
|
|
BiddingRepair(res, "filetext")
|
|
|
logger.Info("第", batchIndex, "批", DbConf.Mongodb.Bidding.Collection, "数据已经加载结束。。。", index)
|
|
|
return &res
|