每晚自动同步时,全量同步
用AmendAndPruneStoreStuff替代PruneMissingStoreSkus与AddCreateFlagForJxStoreSku
This commit is contained in:
@@ -205,7 +205,7 @@ func (c *SyncController) SyncSkuNames() {
|
||||
}
|
||||
|
||||
// @Title 删除本地没有的平台门店商品信息
|
||||
// @Description 删除本地没有的平台门店商品信息
|
||||
// @Description 删除本地没有的平台门店商品信息(已废弃)
|
||||
// @Param token header string true "认证token"
|
||||
// @Param storeIDs query string true "门店ID列表"
|
||||
// @Param vendorIDs query string true "厂商ID列表"
|
||||
@@ -225,7 +225,7 @@ func (c *SyncController) PruneMissingStoreSkus() {
|
||||
}
|
||||
|
||||
// @Title 把京西有,平台无且没有待创建标记的商品加上待创建标记
|
||||
// @Description 把京西有,平台无且没有待创建标记的商品加上待创建标记
|
||||
// @Description 把京西有,平台无且没有待创建标记的商品加上待创建标记(已废弃)
|
||||
// @Param token header string true "认证token"
|
||||
// @Param storeIDs formData string false "门店ID列表"
|
||||
// @Param vendorIDs formData string false "运营商ID列表(京东0 美团1 饿百3)"
|
||||
@@ -244,6 +244,28 @@ func (c *SyncController) AddCreateFlagForJxStoreSku() {
|
||||
})
|
||||
}
|
||||
|
||||
// @Title 把京西有,平台无且没有待创建标记的商品加上待创建标记
|
||||
// @Description 把京西有,平台无且没有待创建标记的商品加上待创建标记
|
||||
// @Param token header string true "认证token"
|
||||
// @Param storeIDs formData string false "门店ID列表"
|
||||
// @Param vendorIDs formData string false "运营商ID列表(京东0 美团1 饿百3)"
|
||||
// @Param optType formData int true "操作方式"
|
||||
// @Param isForce formData bool false "是否强制刷新"
|
||||
// @Param isAsync formData bool false "是否异步操作"
|
||||
// @Param isContinueWhenError formData bool false "单个同步失败是否继续,缺省false"
|
||||
// @Success 200 {object} controllers.CallResult
|
||||
// @Failure 200 {object} controllers.CallResult
|
||||
// @router /AmendAndPruneStoreStuff [post]
|
||||
func (c *SyncController) AmendAndPruneStoreStuff() {
|
||||
c.callAmendAndPruneStoreStuff(func(params *tSyncAmendAndPruneStoreStuffParams) (retVal interface{}, errCode string, err error) {
|
||||
var storeIDs, vendorIDs []int
|
||||
if err = jxutils.Strings2Objs(params.StoreIDs, &storeIDs, params.VendorIDs, &vendorIDs); err == nil {
|
||||
retVal, err = cms.CurVendorSync.AmendAndPruneStoreStuff(params.Ctx, vendorIDs, storeIDs, params.IsAsync, params.IsContinueWhenError, params.OptType, params.IsForce)
|
||||
}
|
||||
return retVal, "", err
|
||||
})
|
||||
}
|
||||
|
||||
// @Title 初始化多门店平台商品库(及商家分类)
|
||||
// @Description 初始化多门店平台商品库(及商家分类)
|
||||
// @Param token header string true "认证token"
|
||||
|
||||
Reference in New Issue
Block a user