- act.SyncAct中,当前逻辑要求传入活动的全部SKU信息(以便低层做一些判断,比如全部删除时要取消,所以暂时删除storeIDs与skuIDs这两个参数
This commit is contained in:
@@ -193,17 +193,15 @@ func (c *ActController) GetActStoreSkuInfo() {
|
||||
// @Param token header string true "认证token"
|
||||
// @Param actID formData int true "活动id"
|
||||
// @Param vendorIDs formData string false "厂商ID列表"
|
||||
// @Param storeIDs formData string false "门店ID列表"
|
||||
// @Param skuIDs formData string false "商品列表"
|
||||
// @Param isAsync formData bool false "是否异步"
|
||||
// @Success 200 {object} controllers.CallResult
|
||||
// @Failure 200 {object} controllers.CallResult
|
||||
// @router /SyncAct [put]
|
||||
func (c *ActController) SyncAct() {
|
||||
c.callSyncAct(func(params *tActSyncActParams) (retVal interface{}, errCode string, err error) {
|
||||
var vendorIDs, storeIDs, skuIDs []int
|
||||
if err = jxutils.Strings2Objs(params.VendorIDs, &vendorIDs, params.StoreIDs, &storeIDs, params.SkuIDs, &skuIDs); err == nil {
|
||||
retVal, err = act.SyncAct(params.Ctx, nil, params.ActID, vendorIDs, storeIDs, skuIDs, params.IsAsync)
|
||||
var vendorIDs /*, storeIDs, skuIDs*/ []int
|
||||
if err = jxutils.Strings2Objs(params.VendorIDs, &vendorIDs /*, params.StoreIDs, &storeIDs, params.SkuIDs, &skuIDs*/); err == nil {
|
||||
retVal, err = act.SyncAct(params.Ctx, nil, params.ActID, vendorIDs, params.IsAsync)
|
||||
}
|
||||
return retVal, "", err
|
||||
})
|
||||
@@ -249,7 +247,7 @@ func (c *ActController) UpdateActStoreSkuBind() {
|
||||
dao.Commit(db)
|
||||
}()
|
||||
if err == nil {
|
||||
retVal, err = act.SyncAct(params.Ctx, nil, params.ActID, nil, nil, nil, params.IsAsync)
|
||||
retVal, err = act.SyncAct(params.Ctx, nil, params.ActID, nil, params.IsAsync)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user