From 245ceeb28c377ffb73de6b937395e2ffafe44e65 Mon Sep 17 00:00:00 2001 From: richboo111 Date: Thu, 25 Aug 2022 10:52:11 +0800 Subject: [PATCH] home --- business/jxstore/cms/store.go | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index 5b55fb7e6..49d07f1af 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -140,7 +140,6 @@ type Info1 struct { WeeklyScore int `json:"weeklyScore"` //店铺每周评分 } type Info2 struct { - StoreID int `json:"storeID"` //门店ID SkuID int `json:"skuID"` //商品ID SkuName string `json:"skuName"` //商品名字 SkuStatus int `json:"skuStatus"` //商品是否可售状态 1可售 0不可售 @@ -5806,7 +5805,6 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis for _, j := range topSkusInfo { if i.StoreID == j.StoreID { data = Info2{ - StoreID: j.StoreID, SkuID: j.SkuID, SkuName: j.Name, SkuStatus: j.Status, @@ -5819,16 +5817,13 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis } multipleData = append(multipleData, data) if len(multipleData) > 0 { - if i.StoreID == multipleData[0].StoreID { - ans = HomePageInfos{ - Info: i, - Info2: multipleData, - } + ans = HomePageInfos{ + Info: i, + Info2: multipleData, } } else { ans = HomePageInfos{ - Info: i, - Info2: nil, + Info: i, } } res = append(res, ans)