home
This commit is contained in:
@@ -140,7 +140,6 @@ type Info1 struct {
|
|||||||
WeeklyScore int `json:"weeklyScore"` //店铺每周评分
|
WeeklyScore int `json:"weeklyScore"` //店铺每周评分
|
||||||
}
|
}
|
||||||
type Info2 struct {
|
type Info2 struct {
|
||||||
StoreID int `json:"storeID"` //门店ID
|
|
||||||
SkuID int `json:"skuID"` //商品ID
|
SkuID int `json:"skuID"` //商品ID
|
||||||
SkuName string `json:"skuName"` //商品名字
|
SkuName string `json:"skuName"` //商品名字
|
||||||
SkuStatus int `json:"skuStatus"` //商品是否可售状态 1可售 0不可售
|
SkuStatus int `json:"skuStatus"` //商品是否可售状态 1可售 0不可售
|
||||||
@@ -5806,7 +5805,6 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
|
|||||||
for _, j := range topSkusInfo {
|
for _, j := range topSkusInfo {
|
||||||
if i.StoreID == j.StoreID {
|
if i.StoreID == j.StoreID {
|
||||||
data = Info2{
|
data = Info2{
|
||||||
StoreID: j.StoreID,
|
|
||||||
SkuID: j.SkuID,
|
SkuID: j.SkuID,
|
||||||
SkuName: j.Name,
|
SkuName: j.Name,
|
||||||
SkuStatus: j.Status,
|
SkuStatus: j.Status,
|
||||||
@@ -5819,16 +5817,13 @@ func GetHomePageByLocation(ctx *jxcontext.Context, lng, lat float64, needWalkDis
|
|||||||
}
|
}
|
||||||
multipleData = append(multipleData, data)
|
multipleData = append(multipleData, data)
|
||||||
if len(multipleData) > 0 {
|
if len(multipleData) > 0 {
|
||||||
if i.StoreID == multipleData[0].StoreID {
|
ans = HomePageInfos{
|
||||||
ans = HomePageInfos{
|
Info: i,
|
||||||
Info: i,
|
Info2: multipleData,
|
||||||
Info2: multipleData,
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
ans = HomePageInfos{
|
ans = HomePageInfos{
|
||||||
Info: i,
|
Info: i,
|
||||||
Info2: nil,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
res = append(res, ans)
|
res = append(res, ans)
|
||||||
|
|||||||
Reference in New Issue
Block a user