上传图片测试

This commit is contained in:
苏尹岚
2020-04-01 09:02:26 +08:00
parent 7ed6bb5dfe
commit d48b54c358

View File

@@ -77,6 +77,8 @@ func RegisterDataResource(ctx *jxcontext.Context, name, resourceURL, mimeType, h
return nil, fmt.Errorf("MIME type:%s非法当前只支持:%s", mimeType, model.GetValidMimeTypeDesc())
}
img, _, err := Binary2Image(resBinary, mimeType)
fmt.Println("testtttt", img)
fmt.Println("testtttt", err)
if err != nil {
return nil, err
}
@@ -136,9 +138,6 @@ func TryRegisterDataResource(ctx *jxcontext.Context, name, resourceURL string, i
if err != nil {
return nil, err
}
fmt.Println("test11", resBinary)
fmt.Println("test22", *dataRes)
fmt.Println("test33", hashCode)
return RegisterDataResource(ctx, name, resourceURL, http.DetectContentType(resBinary), hashCode, resBinary, imgType, isAsyncUpload2Vendor)
}