|
@@ -89,6 +89,7 @@ public class WxWorkHttpUtilNew {
|
|
|
public static <T> T postWithType(String url, Object jsonBody, TypeReference<T> type, Long serverId) {
|
|
public static <T> T postWithType(String url, Object jsonBody, TypeReference<T> type, Long serverId) {
|
|
|
String json = JSON.toJSONString(jsonBody);
|
|
String json = JSON.toJSONString(jsonBody);
|
|
|
String post = post(url, json, null, serverId);
|
|
String post = post(url, json, null, serverId);
|
|
|
|
|
+ log.info("请求服务器地址:{},请求参数:{},返回数据:{},请求时间:{}", url, json, post, LocalDateTime.now());
|
|
|
WxWorkResponseCodeDTO respone = JSON.parseObject(post, WxWorkResponseCodeDTO.class);
|
|
WxWorkResponseCodeDTO respone = JSON.parseObject(post, WxWorkResponseCodeDTO.class);
|
|
|
if(respone.getErrcode() != 0){
|
|
if(respone.getErrcode() != 0){
|
|
|
log.error("请求服务器地址:{},请求参数:{},返回数据:{},请求时间:{}", url, json, JSON.toJSONString(respone), LocalDateTime.now());
|
|
log.error("请求服务器地址:{},请求参数:{},返回数据:{},请求时间:{}", url, json, JSON.toJSONString(respone), LocalDateTime.now());
|