| | |
| | | if (notifyDto.getSendCustomData()) { |
| | | //自定义消息格式 |
| | | NotifyCustomDataDto customData = notifyDto.getCustomData(); |
| | | apiLog.setUrl(customData.getUri() + customData.getPath()); |
| | | apiLog.setRequest(customData.getData()); |
| | | apiLog.setCreateTime(new Date()); |
| | | |
| | | response = new HttpHandler.Builder() |
| | | .setUri(customData.getUri()) |
| | | .setPath(customData.getPath()) |
| | | .setJson(customData.getData()) |
| | | .build() |
| | | .doPost(); |
| | | |
| | | apiLog.setUrl(customData.getUri() + customData.getPath()); |
| | | apiLog.setRequest(customData.getData()); |
| | | apiLog.setCreateTime(new Date()); |
| | | }else { |
| | | apiLog.setUrl(notifyUri + notifyUriPath); |
| | | apiLog.setRequest(JSON.toJSONString(notifyDto)); |
| | | apiLog.setCreateTime(new Date()); |
| | | |
| | | response = new HttpHandler.Builder() |
| | | .setUri(notifyUri) |
| | | .setPath(notifyUriPath) |
| | | .setJson(JSON.toJSONString(notifyDto)) |
| | | .build() |
| | | .doPost(); |
| | | |
| | | apiLog.setUrl(notifyUri + notifyUriPath); |
| | | apiLog.setRequest(JSON.toJSONString(notifyDto)); |
| | | apiLog.setCreateTime(new Date()); |
| | | } |
| | | |
| | | apiLog.setResponse(response); |