创建标品优化
This commit is contained in:
@@ -1887,8 +1887,10 @@ func CreateUpcSkuByExcelBin(ctx *jxcontext.Context, reader io.Reader, categoryID
|
||||
var result *aliupcapi.GetAliUpcInfoResult
|
||||
upcDepot, err := dao.GetUpcDepot(db, *v.Upc)
|
||||
if upcDepot == nil {
|
||||
result, _ = api.AliUpcAPI.GetAliUpcInfo(*v.Upc)
|
||||
err = dao.InsertUpcDepot(db, result)
|
||||
result, err = api.AliUpcAPI.GetAliUpcInfo(*v.Upc)
|
||||
if err == nil {
|
||||
err = dao.InsertUpcDepot(db, result)
|
||||
}
|
||||
} else {
|
||||
result = upcDepot
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user