- 如果得到的京东平台活动没有有效的sku,则忽略
This commit is contained in:
@@ -402,6 +402,10 @@ func GetStoresSkusInfo(db *DaoDB, storeIDs, skuIDs []int) (storeSkuList []*model
|
||||
|
||||
// vendorID, vendorStoreIDs和vendorSkuIDs都是必须参数
|
||||
func GetStoresSkusInfoByVendorInfo(db *DaoDB, vendorID int, vendorStoreIDs, vendorSkuIDs []string) (storeSkuList []*StoreSkuBindWithVendorInfo, err error) {
|
||||
if len(vendorStoreIDs) == 0 || len(vendorSkuIDs) == 0 {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
sql := `
|
||||
SELECT t1.*,
|
||||
%s.%s_id vendor_sku_id, t2.vendor_store_id
|
||||
|
||||
@@ -307,7 +307,7 @@ func (c *PurchaseHandler) onActMsg(msg *jdapi.CallbackOrderMsg) (retVal *jdapi.C
|
||||
promotionID := msg.BillID
|
||||
if !partner.CurActManager.IsVendorActExist(jxcontext.AdminCtx, promotionID, model.VendorIDJD) {
|
||||
act, actStoreSkuList, err := getActFromJD(promotionID)
|
||||
if err == nil {
|
||||
if err == nil && len(actStoreSkuList) > 0 {
|
||||
_, err = partner.CurActManager.CreateActFromVendor(jxcontext.AdminCtx, act, actStoreSkuList)
|
||||
}
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user