This commit is contained in:
qidongsheng
2020-07-06 11:13:31 +08:00
parent 33b33e04bf
commit a6f7fc06cb
4 changed files with 24 additions and 2 deletions

View File

@@ -2441,7 +2441,12 @@ func GetTopSkusByStoreIDs(ctx *jxcontext.Context, storeIDs []int) (storeSkuNameE
func GetTopSkusByCityCode(ctx *jxcontext.Context, cityCode, storeID int) (skuNameAndPlaceList []*dao.SkuNameAndPlace, err error) {
db := dao.GetDB()
orderCreate := time.Now().AddDate(0, -1, 0)
skuNameAndPlace, err := dao.GetTopSkusByCityCode(db, cityCode, orderCreate)
var skuNameAndPlace []*dao.SkuNameAndPlace
if cityCode > 0 {
skuNameAndPlace, err = dao.GetTopSkusByCityCode(db, cityCode, orderCreate)
} else {
skuNameAndPlace, err = dao.GetTopSkusByNoCityCode(db, cityCode, orderCreate)
}
if storeID > 0 {
var skuNameList []*model.SkuName
//不可售的商品nameID列表