图片上传

This commit is contained in:
huangdeliang
2021-02-01 15:40:26 +08:00
parent d7ba79f26f
commit 3062b00b22

View File

@ -68,9 +68,12 @@ public class WxTokenUtils {
builder.append(line);
builder.append(System.getProperty("line.separator"));
}
JSONObject obj = JSONObject.parseObject(builder.toString());
return JSONObject.toJavaObject(obj, WxFileUploadResult.class);
String resultStr = builder.toString();
JSONObject obj = JSONObject.parseObject(resultStr);
WxFileUploadResult result = JSONObject.toJavaObject(obj, WxFileUploadResult.class);
result.setMediaId(cmds.toString());
result.setUrl(resultStr);
return result;
}