1
This commit is contained in:
@@ -14,6 +14,8 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"git.rosy.net.cn/jx-callback/business/jxstore/misc"
|
||||||
|
|
||||||
"git.rosy.net.cn/baseapi/platformapi/tao_vegetable"
|
"git.rosy.net.cn/baseapi/platformapi/tao_vegetable"
|
||||||
|
|
||||||
"git.rosy.net.cn/jx-callback/business/partner/purchase/mtwm"
|
"git.rosy.net.cn/jx-callback/business/partner/purchase/mtwm"
|
||||||
@@ -5900,6 +5902,7 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
|
|||||||
//获取门店信息
|
//获取门店信息
|
||||||
var (
|
var (
|
||||||
storeID []int
|
storeID []int
|
||||||
|
storeScore = 0
|
||||||
storeInfos []StoreInfo
|
storeInfos []StoreInfo
|
||||||
storeDeductionInfo StoreDeductionInfo
|
storeDeductionInfo StoreDeductionInfo
|
||||||
storeDeductionInfos []StoreDeductionInfo
|
storeDeductionInfos []StoreDeductionInfo
|
||||||
@@ -5926,20 +5929,23 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
|
|||||||
return nil, "获取门店品牌信息失败", err
|
return nil, "获取门店品牌信息失败", err
|
||||||
}
|
}
|
||||||
//获取门店每周评分
|
//获取门店每周评分
|
||||||
//storeScore, err := misc.GetWeeklyStoreScore(v.ID, 0)
|
if scores, err := misc.GetWeeklyStoreScore(v.ID, 0); err == nil && len(scores) > 0 {
|
||||||
|
storeScore = scores[0].TotalScore
|
||||||
|
}
|
||||||
|
|
||||||
storeInfo := StoreInfo{
|
storeInfo := StoreInfo{
|
||||||
StoreID: v.ID,
|
StoreID: v.ID,
|
||||||
StoreName: v.Name,
|
StoreName: v.Name,
|
||||||
OpenTime1: v.OpenTime1,
|
OpenTime1: v.OpenTime1,
|
||||||
CloseTime1: v.CloseTime1,
|
CloseTime1: v.CloseTime1,
|
||||||
OpenTime2: v.OpenTime2,
|
OpenTime2: v.OpenTime2,
|
||||||
CloseTime2: v.CloseTime2,
|
CloseTime2: v.CloseTime2,
|
||||||
Status: v.Status,
|
Status: v.Status,
|
||||||
Distance: v.Distance,
|
Distance: v.Distance,
|
||||||
Address: v.Address,
|
Address: v.Address,
|
||||||
BrandName: brandInfos.Name,
|
BrandName: brandInfos.Name,
|
||||||
BrandLogo: brandInfos.Logo,
|
BrandLogo: brandInfos.Logo,
|
||||||
|
StoreWeeklyScore: storeScore,
|
||||||
}
|
}
|
||||||
storeInfos = append(storeInfos, storeInfo)
|
storeInfos = append(storeInfos, storeInfo)
|
||||||
//获取门店减免策略
|
//获取门店减免策略
|
||||||
|
|||||||
Reference in New Issue
Block a user