| | |
| | | if (!DateUtil.verification(startTime, DateUtil.formatter)) { |
| | | throw new ControllerException(ErrorCode.ERROR100.getCode(), "开始时间格式错误,正确格式为: " + DateUtil.formatter); |
| | | } |
| | | startTimeStamp = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestamp(startTime); |
| | | startTimeStamp = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestampMs(startTime); |
| | | |
| | | } |
| | | if (endTime != null ) { |
| | | if (!DateUtil.verification(endTime, DateUtil.formatter)) { |
| | | throw new ControllerException(ErrorCode.ERROR100.getCode(), "结束时间格式错误,正确格式为: " + DateUtil.formatter); |
| | | } |
| | | endTimeStamp = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestamp(endTime); |
| | | endTimeStamp = DateUtil.yyyy_MM_dd_HH_mm_ssToTimestampMs(endTime); |
| | | |
| | | } |
| | | PageHelper.startPage(page, count); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public JSONArray queryTask(String app, String stream, String callId, String taskId, String mediaServerId, Boolean isEnd) { |
| | | public JSONArray queryTask(String app, String stream, String callId, String taskId, String mediaServerId, |
| | | Boolean isEnd, String scheme) { |
| | | MediaServerItem mediaServerItem = null; |
| | | if (mediaServerId == null) { |
| | | mediaServerItem = mediaServerService.getDefaultMediaServer(); |
| | |
| | | if (mediaServerItem == null) { |
| | | throw new ControllerException(ErrorCode.ERROR100.getCode(), "未找到可用的流媒体"); |
| | | } |
| | | JSONObject result = assistRESTfulUtils.queryTaskList(mediaServerItem, app, stream, callId, taskId, isEnd); |
| | | |
| | | JSONObject result = assistRESTfulUtils.queryTaskList(mediaServerItem, app, stream, callId, taskId, isEnd, scheme); |
| | | if (result == null || result.getInteger("code") != 0) { |
| | | throw new ControllerException(ErrorCode.ERROR100.getCode(), result == null ? "查询任务列表失败" : result.getString("msg")); |
| | | } |