首页推荐商家

This commit is contained in:
richboo111
2022-08-24 18:18:25 +08:00
parent f204448930
commit 951bad012e

View File

@@ -8,7 +8,6 @@ import (
"fmt" "fmt"
"git.rosy.net.cn/jx-callback/business/jxstore/common" "git.rosy.net.cn/jx-callback/business/jxstore/common"
"git.rosy.net.cn/jx-callback/business/jxstore/event" "git.rosy.net.cn/jx-callback/business/jxstore/event"
"git.rosy.net.cn/jx-callback/business/jxstore/misc"
"io" "io"
"math" "math"
"mime/multipart" "mime/multipart"
@@ -5759,10 +5758,10 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
return nil, "获取门店减免策略失败", err return nil, "获取门店减免策略失败", err
} }
//获取店铺每周评分 //获取店铺每周评分
weeklyScore, err := misc.GetWeeklyStoreScore(v.ID, -1) //weeklyScore, err := misc.GetWeeklyStoreScore(v.ID, -1)
if err != nil { //if err != nil {
return nil, "获取店铺每周评分失败", err // return nil, "获取店铺每周评分失败", err
} //}
for _, k := range storePolicy { for _, k := range storePolicy {
if k.StoreID == v.ID { if k.StoreID == v.ID {
tmp1 := Info1{ tmp1 := Info1{
@@ -5779,7 +5778,7 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
BrandLogo: brandInfos.Logo, BrandLogo: brandInfos.Logo,
DeliveryFeeDeductionSill: storePolicy[0].DeliveryFeeDeductionSill, DeliveryFeeDeductionSill: storePolicy[0].DeliveryFeeDeductionSill,
DeliveryFeeDeductionFee: storePolicy[0].DeliveryFeeDeductionFee, DeliveryFeeDeductionFee: storePolicy[0].DeliveryFeeDeductionFee,
WeeklyScore: weeklyScore[0].TotalScore, //WeeklyScore: weeklyScore[0].TotalScore,
} }
tmp1s = append(tmp1s, tmp1) tmp1s = append(tmp1s, tmp1)
} }
@@ -5807,14 +5806,14 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
BrandLogo: i.BrandLogo, BrandLogo: i.BrandLogo,
DeliveryFeeDeductionSill: i.DeliveryFeeDeductionSill, DeliveryFeeDeductionSill: i.DeliveryFeeDeductionSill,
DeliveryFeeDeductionFee: i.DeliveryFeeDeductionFee, DeliveryFeeDeductionFee: i.DeliveryFeeDeductionFee,
WeeklyScore: i.WeeklyScore, //WeeklyScore: i.WeeklyScore,
SkuID: j.SkuID, SkuID: j.SkuID,
SkuName: j.Name, SkuName: j.Name,
SkuStatus: j.Status, SkuStatus: j.Status,
BestSeller: j.BestSeller, BestSeller: j.BestSeller,
Img: j.Img, Img: j.Img,
Price: j.Price, Price: j.Price,
Unit: j.Unit, Unit: j.Unit,
} }
multipleData = append(multipleData, data) multipleData = append(multipleData, data)
} }