This commit is contained in:
邹宗楠
2024-10-09 16:14:31 +08:00
parent 8311d3996e
commit 1f6dc7185e
4 changed files with 8 additions and 11 deletions

View File

@@ -6014,7 +6014,9 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
StoreSkuInfos []StoreSkuInfo
homePages []HomePageInfos
)
beginTime := time.Now()
locationList, err := common.GetStoreListByLocation(ctx, lng, lat, 20000, needWalkDistance, false, 0)
baseapi.SugarLogger.Infof("GetTopSkusByStoreIDs usedMilliSecond------2:%d", time.Now().Sub(beginTime)/time.Millisecond)
if err != nil {
return nil, "经纬度获取推荐门店失败", err
}
@@ -6046,6 +6048,7 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
StoreSkuInfos = append(StoreSkuInfos, storeSkuInfo)
}
baseapi.SugarLogger.Infof("GetTopSkusByStoreIDs usedMilliSecond------3:%d", time.Now().Sub(beginTime)/time.Millisecond)
for _, v := range filterStore {
//获取门店品牌信息
brandInfos, err := dao.GetStoreBrandInfos(v.ID)
@@ -6113,6 +6116,7 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
}
homePages = append(homePages, homePage)
}
baseapi.SugarLogger.Infof("GetTopSkusByStoreIDs usedMilliSecond------4:%d", time.Now().Sub(beginTime)/time.Millisecond)
return homePages, "", nil
}