- GetStores返回订单数据OrderCount
This commit is contained in:
@@ -45,6 +45,8 @@ type StoreExt struct {
|
|||||||
CourierMapStr string `json:"-"`
|
CourierMapStr string `json:"-"`
|
||||||
StoreMaps []interface{} `orm:"-"`
|
StoreMaps []interface{} `orm:"-"`
|
||||||
CourierMaps []interface{} `orm:"-"`
|
CourierMaps []interface{} `orm:"-"`
|
||||||
|
|
||||||
|
OrderCount int `json:"orderCount"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type StoresInfo struct {
|
type StoresInfo struct {
|
||||||
@@ -387,6 +389,7 @@ func filterStoreByOrderInfo(db *dao.DaoDB, inStores []*StoreExt, orderTimeFrom,
|
|||||||
for _, v := range inStores {
|
for _, v := range inStores {
|
||||||
orderCount := storeOrderCountMap[v.ID]
|
orderCount := storeOrderCountMap[v.ID]
|
||||||
if orderCount >= orderCountFrom && orderCount <= orderCountTo {
|
if orderCount >= orderCountFrom && orderCount <= orderCountTo {
|
||||||
|
v.OrderCount = orderCount
|
||||||
outStores = append(outStores, v)
|
outStores = append(outStores, v)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user