Commit 0a075dd0 authored by zhangyingbin's avatar zhangyingbin

1、96333应急处置系统,警情接警之后正常填报警情,点击警情处置,查看详情,未关联通话记录

2、去掉地图滚动消息中,预警消息
parent 25de7421
...@@ -77,29 +77,29 @@ public class MsgLogServiceImpl extends BaseService<MsgLogDto, MsgLog, MsgLogMapp ...@@ -77,29 +77,29 @@ public class MsgLogServiceImpl extends BaseService<MsgLogDto, MsgLog, MsgLogMapp
alertMsgDtoList.add(alertMsgDto); alertMsgDtoList.add(alertMsgDto);
}); });
} }
// 查询气瓶预警消息 // // 查询气瓶预警消息
LambdaQueryWrapper<MsgLog> wrapper = new LambdaQueryWrapper<>(); // LambdaQueryWrapper<MsgLog> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(MsgLog::getTerminalType, "WEB"); // wrapper.eq(MsgLog::getTerminalType, "WEB");
//企业根据企业名称筛选,监管机构根据区域筛选 // //企业根据企业名称筛选,监管机构根据区域筛选
ReginParams reginParams = citInfoService.getReginParams(); // ReginParams reginParams = citInfoService.getReginParams();
if(!"company".equals(reginParams.getCompany().getLevel())){ // if(!"company".equals(reginParams.getCompany().getLevel())){
wrapper.like(MsgLog::getRegionCode,reginParams.getCompany().getRegionCode()); // wrapper.like(MsgLog::getRegionCode,reginParams.getCompany().getRegionCode());
} else { // } else {
wrapper.eq(MsgLog::getCompanyName,reginParams.getCompany().getCompanyName()); // wrapper.eq(MsgLog::getCompanyName,reginParams.getCompany().getCompanyName());
} // }
List<MsgLog> msgLogList = this.list(wrapper); // List<MsgLog> msgLogList = this.list(wrapper);
if (!ValidationUtil.isEmpty(msgLogList)) { // if (!ValidationUtil.isEmpty(msgLogList)) {
msgLogList.forEach(msg -> { // msgLogList.forEach(msg -> {
AlertMsgDto alertMsgDto = new AlertMsgDto(); // AlertMsgDto alertMsgDto = new AlertMsgDto();
alertMsgDto.setBody(msg.getBody()); // alertMsgDto.setBody(msg.getBody());
alertMsgDto.setFrom("cylinder"); // alertMsgDto.setFrom("cylinder");
alertMsgDto.setRelationId(String.valueOf(msg.getSequenceNbr())); // alertMsgDto.setRelationId(String.valueOf(msg.getSequenceNbr()));
alertMsgDto.setTime(msg.getSendTime()); // alertMsgDto.setTime(msg.getSendTime());
alertMsgDto.setType(msg.getMsgTypeName()); // alertMsgDto.setType(msg.getMsgTypeName());
//
alertMsgDtoList.add(alertMsgDto); // alertMsgDtoList.add(alertMsgDto);
}); // });
} // }
return alertMsgDtoList; return alertMsgDtoList;
} }
......
...@@ -83,7 +83,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -83,7 +83,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
// 首先查找未完成 且失败次数少于5 的 记录 // 首先查找未完成 且失败次数少于5 的 记录
List<VoiceRecordLog> logList = this.list(new LambdaQueryWrapper<VoiceRecordLog>().eq(VoiceRecordLog::getIsDeal,false).lt(VoiceRecordLog::getDealTimes,5)); List<VoiceRecordLog> logList = this.list(new LambdaQueryWrapper<VoiceRecordLog>().eq(VoiceRecordLog::getIsDeal,false).lt(VoiceRecordLog::getDealTimes,5));
if(logList != null && logList.size() >0) { if(logList != null && logList.size() >0) {
logList.stream().forEach(l -> { for(VoiceRecordLog l : logList){
// 保存录音 修改状态 发送mqtt 通知 // 保存录音 修改状态 发送mqtt 通知
// 获取通话人信息 // 获取通话人信息
Integer dealTimes = 1; Integer dealTimes = 1;
...@@ -91,10 +91,15 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -91,10 +91,15 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
dealTimes += l.getDealTimes(); dealTimes += l.getDealTimes();
} }
l.setDealTimes(dealTimes); l.setDealTimes(dealTimes);
JSONArray ctiInfos = ctiService.getCallInfo(l.getConnectId()); JSONArray ctiInfos = new JSONArray();
try {
ctiInfos = ctiService.getCallInfo(l.getConnectId());
}catch (Exception e) {
continue;
}
if(ctiInfos == null || ctiInfos.size() == 0) { if(ctiInfos == null || ctiInfos.size() == 0) {
this.updateById(l); this.updateById(l);
return; continue;
} }
VoiceRecordFileDto model = new VoiceRecordFileDto(); VoiceRecordFileDto model = new VoiceRecordFileDto();
JSONObject recordInfo = ctiInfos.getJSONObject(0); JSONObject recordInfo = ctiInfos.getJSONObject(0);
...@@ -108,7 +113,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -108,7 +113,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
telEndTime = DateUtils.longStr2Date(recordInfo.getString("hangupTime")); telEndTime = DateUtils.longStr2Date(recordInfo.getString("hangupTime"));
} catch (Exception e) { } catch (Exception e) {
this.updateById(l); this.updateById(l);
return; continue;
} }
int times = recordInfo.getIntValue("times"); int times = recordInfo.getIntValue("times");
model.setTelTime(DateUtils.secondsToTimeStr(times)); model.setTelTime(DateUtils.secondsToTimeStr(times));
...@@ -126,11 +131,11 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -126,11 +131,11 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
this.updateById(l); this.updateById(l);
return; continue;
} }
if(downloadFile.isEmpty()) { if(downloadFile.isEmpty()) {
this.updateById(l); this.updateById(l);
return; continue;
} }
for(Map.Entry<String,String> file : downloadFile.entrySet()) { for(Map.Entry<String,String> file : downloadFile.entrySet()) {
model.setFilePath(file.getKey()); model.setFilePath(file.getKey());
...@@ -138,7 +143,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -138,7 +143,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
AlertCalledFormDto alertDto = iAlertCalledService.selectAlertCalledByIdNoCache(model.getAlertId()); AlertCalledFormDto alertDto = iAlertCalledService.selectAlertCalledByIdNoCache(model.getAlertId());
if(alertDto == null || alertDto.getAlertCalledDto() == null) { if(alertDto == null || alertDto.getAlertCalledDto() == null) {
this.updateById(l); this.updateById(l);
return; continue;
} }
model.setAlertStage(alertDto.getAlertCalledDto().getAlertStage()); model.setAlertStage(alertDto.getAlertCalledDto().getAlertStage());
model.setAlertStageCode(alertDto.getAlertCalledDto().getAlertStageCode()); model.setAlertStageCode(alertDto.getAlertCalledDto().getAlertStageCode());
...@@ -159,7 +164,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi ...@@ -159,7 +164,7 @@ public class VoiceRecordLogServiceImpl extends BaseService<VoiceRecordLogDto,Voi
} }
l.setIsDeal(true); l.setIsDeal(true);
this.updateById(l); this.updateById(l);
}); };
} }
System.out.println("执行通话记录任务"); System.out.println("执行通话记录任务");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment