|
|
|
|
@ -214,16 +214,24 @@ public class TricycleController { |
|
|
|
|
|
|
|
|
|
@GetMapping("/getSquadronVillageList") |
|
|
|
|
@ApiOperation(value = "获取中队绑定村庄列表") |
|
|
|
|
public ServerResponse<?> getSquadronVillageList(@RequestParam String nuserId){ |
|
|
|
|
public ServerResponse<?> getSquadronVillageList(HttpServletRequest request, |
|
|
|
|
@RequestParam String nuserId){ |
|
|
|
|
|
|
|
|
|
log.info("/getSquadronVillageList(【三轮车】获取中队绑定村庄列表)接口被调用, 调用ip: {},入参:{}", request.getRemoteAddr(),nuserId); |
|
|
|
|
|
|
|
|
|
List<StreetCommunity> streetCommunityBySquadron = configMapper.getStreetCommunityBySquadron(nuserId); |
|
|
|
|
|
|
|
|
|
log.info("/getSquadronVillageList(【三轮车】获取中队绑定村庄列表)接口数据返回,调用ip: {}, 出参:{}", request.getRemoteAddr(), streetCommunityBySquadron); |
|
|
|
|
|
|
|
|
|
return ServerResponse.ok(streetCommunityBySquadron); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@GetMapping("/getWarningDetails") |
|
|
|
|
@ApiOperation(value = "预警处理/分配操作详情页") |
|
|
|
|
public ServerResponse<?> getWarningDetails(@RequestParam String warningId){ |
|
|
|
|
public ServerResponse<?> getWarningDetails(HttpServletRequest request, |
|
|
|
|
@RequestParam String warningId){ |
|
|
|
|
|
|
|
|
|
log.info("/getWarningDetails(【三轮车】预警处理/分配操作详情页)接口被调用, 调用ip: {},入参:{}", request.getRemoteAddr(),warningId); |
|
|
|
|
|
|
|
|
|
List<TricycleWarningDetailVO> warningDetails = tricycleService.getWarningDetails(warningId); |
|
|
|
|
|
|
|
|
|
@ -232,17 +240,25 @@ public class TricycleController { |
|
|
|
|
item.setWarningTimeFormat(dateFormat.format(item.getWarningTime())); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
log.info("/getWarningDetails(【三轮车】预警处理/分配操作详情页)接口数据返回,调用ip: {}, 出参:{}", request.getRemoteAddr(), warningDetails); |
|
|
|
|
|
|
|
|
|
return ServerResponse.ok(warningDetails); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@GetMapping("/submitDistributionStatus") |
|
|
|
|
@ApiOperation(value = "中队民警提交预警分配状态") |
|
|
|
|
public ServerResponse<?> submitDistributionStatus(@RequestParam String warningId, @RequestParam String sqCode){ |
|
|
|
|
public ServerResponse<?> submitDistributionStatus(HttpServletRequest request, |
|
|
|
|
@RequestParam String warningId, |
|
|
|
|
@RequestParam String sqCode){ |
|
|
|
|
|
|
|
|
|
log.info("/submitDistributionStatus(【三轮车】中队民警提交预警分配状态)接口被调用, 调用ip: {},入参:{},{}", request.getRemoteAddr(),warningId,sqCode); |
|
|
|
|
|
|
|
|
|
int affectRows = tricycleService.submitDistributionStatus(warningId, sqCode); |
|
|
|
|
if(affectRows > 0){ |
|
|
|
|
// 变更分配状态为已分配
|
|
|
|
|
tricycleService.updateWarningDistributionStatus("1", warningId); |
|
|
|
|
|
|
|
|
|
log.info("/submitDistributionStatus(【三轮车】中队民警提交预警分配状态)接口数据返回,调用ip: {}, 出参:{}", request.getRemoteAddr(), "提交分配状态成功"); |
|
|
|
|
return ServerResponse.ok("提交分配状态成功"); |
|
|
|
|
}else{ |
|
|
|
|
return ServerResponse.error("提交分配状态失败"); |
|
|
|
|
@ -251,12 +267,17 @@ public class TricycleController { |
|
|
|
|
|
|
|
|
|
@PostMapping("/saveTricycleWarningHandle") |
|
|
|
|
@ApiOperation(value = "提交预警处理内容") |
|
|
|
|
public ServerResponse<?> saveTricycleWarningHandle(@RequestBody TricycleWarningResultsVO resultsVO){ |
|
|
|
|
public ServerResponse<?> saveTricycleWarningHandle(HttpServletRequest request, |
|
|
|
|
@RequestBody TricycleWarningResultsVO resultsVO){ |
|
|
|
|
|
|
|
|
|
log.info("/saveTricycleWarningHandle(【三轮车】提交预警处理内容)接口被调用, 调用ip: {},入参:{}", request.getRemoteAddr(),resultsVO); |
|
|
|
|
|
|
|
|
|
int affectRows = tricycleService.saveTricycleWarningHandle(resultsVO); |
|
|
|
|
if(affectRows > 0){ |
|
|
|
|
// 更新数据处理状态为已处理
|
|
|
|
|
tricycleService.updateWarningStatus("1", resultsVO.getWarningId()); |
|
|
|
|
|
|
|
|
|
log.info("/saveTricycleWarningHandle(【三轮车】提交预警处理内容)接口数据返回,调用ip: {}, 出参:{}", request.getRemoteAddr(),""); |
|
|
|
|
return ServerResponse.ok("提交预警处理数据成功"); |
|
|
|
|
}else{ |
|
|
|
|
return ServerResponse.error("提交预警处理数据失败"); |
|
|
|
|
@ -265,7 +286,10 @@ public class TricycleController { |
|
|
|
|
|
|
|
|
|
@GetMapping("/getHandleTypeEnum") |
|
|
|
|
@ApiOperation(value = "处理类型字典") |
|
|
|
|
public ServerResponse<?> getHandleTypeEnum(@RequestParam String nuserId){ |
|
|
|
|
public ServerResponse<?> getHandleTypeEnum(HttpServletRequest request, |
|
|
|
|
@RequestParam String nuserId){ |
|
|
|
|
|
|
|
|
|
log.info("/getHandleTypeEnum(【三轮车】处理类型字典)接口被调用, 调用ip: {},入参:{}", request.getRemoteAddr(),nuserId); |
|
|
|
|
int roleFlag = 0; |
|
|
|
|
|
|
|
|
|
List<String> handleType = new ArrayList<>(); |
|
|
|
|
@ -293,7 +317,7 @@ public class TricycleController { |
|
|
|
|
handleType.add(HandleEnum.PUBLICITY_AND_EDUCATION.getName()); |
|
|
|
|
handleType.add(HandleEnum.ILLEGAL_PUNISHMENT.getName()); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
log.info("/getHandleTypeEnum(【三轮车】处理类型字典)接口数据返回,调用ip: {}, 出参:{}", request.getRemoteAddr(), handleType); |
|
|
|
|
return ServerResponse.ok(handleType); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|