根据名字查询京东upc

This commit is contained in:
苏尹岚
2019-12-16 14:21:19 +08:00
parent f5166d59b6
commit 1f1835fa2d
4 changed files with 49 additions and 14 deletions

View File

@@ -379,13 +379,14 @@ func (c *SkuController) GetStoreSkuSalesInfo() {
// @Title 根据名字查询京东商品UPC信息
// @Description 根据名字查询京东商品UPC信息
// @Param token header string true "认证token"
// @Param name formData string true "商品名"
// @Param name query string false "商品名"
// @Param upcCode query string false "upcCode,不支持模糊"
// @Success 200 {object} controllers.CallResult
// @Failure 200 {object} controllers.CallResult
// @router /GetJdUpcCodeByName [post]
// @router /GetJdUpcCodeByName [get]
func (c *SkuController) GetJdUpcCodeByName() {
c.callGetJdUpcCodeByName(func(params *tSkuGetJdUpcCodeByNameParams) (retVal interface{}, errCode string, err error) {
retVal, err = cms.GetJdUpcCodeByName(params.Ctx, params.Name)
retVal, err = cms.GetJdUpcCodeByName(params.Ctx, params.Name, params.UpcCode)
return retVal, "", err
})
}