From 51e9cb430426b76b01f7099030cb9c2308a3155c Mon Sep 17 00:00:00 2001 From: suyl <770236076@qq.com> Date: Fri, 25 Jun 2021 09:55:12 +0800 Subject: [PATCH] aa --- business/jxstore/cms/store_sku.go | 10 +++++----- controllers/cms_store_sku.go | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/business/jxstore/cms/store_sku.go b/business/jxstore/cms/store_sku.go index 6e063ef94..31bcca1cf 100644 --- a/business/jxstore/cms/store_sku.go +++ b/business/jxstore/cms/store_sku.go @@ -1110,7 +1110,7 @@ type GetStoresSkusSaleInfoNewResult struct { SpecUnit string `json:"specUnit"` } -func GetStoresSkusSaleInfoNew(ctx *jxcontext.Context, vendorIDs, storeIDs, skuIDs, skuNameIDs []int, fromTime, toTime string, dataMap map[string]interface{}, sortType int, keyword string, offset, pageSize int) (pageInfo *model.PagedInfo, err error) { +func GetStoresSkusSaleInfoNew(ctx *jxcontext.Context, storeIDs, skuIDs, skuNameIDs []int, fromTime, toTime string, dataMap map[string]interface{}, sortType int, keyword string, offset, pageSize int) (pageInfo *model.PagedInfo, err error) { var ( db = dao.GetDB() list []*GetStoresSkusSaleInfoNewResult @@ -1137,10 +1137,10 @@ func GetStoresSkusSaleInfoNew(ctx *jxcontext.Context, vendorIDs, storeIDs, skuID WHERE a.order_created_at > ? AND a.order_created_at < ? ` sqlParams := []interface{}{utils.Str2Time(fromTime), utils.Str2Time(toTime)} - if len(vendorIDs) > 0 { - sql += " AND a.vendor_id IN (" + dao.GenQuestionMarks(len(vendorIDs)) + ")" - sqlParams = append(sqlParams, vendorIDs) - } + //if len(vendorIDs) > 0 { + // sql += " AND a.vendor_id IN (" + dao.GenQuestionMarks(len(vendorIDs)) + ")" + // sqlParams = append(sqlParams, vendorIDs) + //} if len(storeIDs) > 0 { sql += " AND d.id IN (" + dao.GenQuestionMarks(len(storeIDs)) + ")" sqlParams = append(sqlParams, storeIDs) diff --git a/controllers/cms_store_sku.go b/controllers/cms_store_sku.go index fd0aa4bcb..7be612dd4 100644 --- a/controllers/cms_store_sku.go +++ b/controllers/cms_store_sku.go @@ -351,12 +351,12 @@ func (c *StoreSkuController) UpdateStoresSkusSale() { func (c *StoreSkuController) GetStoresSkusSaleInfo() { c.callGetStoresSkusSaleInfo(func(params *tStoreSkuGetStoresSkusSaleInfoParams) (retVal interface{}, errCode string, err error) { var ( - storeIDs, skuIDs, skuNameIDs, vendorIDs []int + storeIDs, skuIDs, skuNameIDs []int ) - if err = jxutils.Strings2Objs(params.StoreIDs, &storeIDs, params.SkuIDs, &skuIDs, params.SkuNameIDs, &skuNameIDs, params.VendorIDs, &vendorIDs); err != nil { + if err = jxutils.Strings2Objs(params.StoreIDs, &storeIDs, params.SkuIDs, &skuIDs, params.SkuNameIDs, &skuNameIDs); err != nil { return retVal, "", err } - retVal, err = cms.GetStoresSkusSaleInfoNew(params.Ctx, vendorIDs, storeIDs, skuIDs, skuNameIDs, params.FromTime, params.ToTime, params.MapData, params.SortType, params.Keyword, params.Offset, params.PageSize) + retVal, err = cms.GetStoresSkusSaleInfoNew(params.Ctx, storeIDs, skuIDs, skuNameIDs, params.FromTime, params.ToTime, params.MapData, params.SortType, params.Keyword, params.Offset, params.PageSize) return retVal, "", err }) }