创建标品测试

This commit is contained in:
苏尹岚
2020-04-22 13:58:09 +08:00
parent c00d25e785
commit d22cbdee9b

View File

@@ -1873,8 +1873,8 @@ func CreateUpcSkuByExcelBin(ctx *jxcontext.Context, reader io.Reader, categoryID
retVal = []*CreateUpcSkuByExcelErr{buildCreateUpcSkuByExcelErr(v, "商品的条码不能为空!")} retVal = []*CreateUpcSkuByExcelErr{buildCreateUpcSkuByExcelErr(v, "商品的条码不能为空!")}
return retVal, err return retVal, err
} }
skuNames, _ := dao.GetSkuNames(db, nil, []string{*v.Upc}, "", false) skuNames, err := dao.GetSkuNames(db, nil, []string{*v.Upc}, "", false)
fmt.Println(utils.Format4Output(skuNames, false)) fmt.Println(utils.Format4Output(err, false))
if len(skuNames) > 0 { if len(skuNames) > 0 {
fmt.Println("test111111111111111111111111111111111111111") fmt.Println("test111111111111111111111111111111111111111")
retVal = []*CreateUpcSkuByExcelErr{buildCreateUpcSkuByExcelErr(v, "商品在京西库中已存在!")} retVal = []*CreateUpcSkuByExcelErr{buildCreateUpcSkuByExcelErr(v, "商品在京西库中已存在!")}