diff --git a/src/main/java/com/biutag/supervision/service/ModelClueService.java b/src/main/java/com/biutag/supervision/service/ModelClueService.java index 30b8722..2a1ed38 100644 --- a/src/main/java/com/biutag/supervision/service/ModelClueService.java +++ b/src/main/java/com/biutag/supervision/service/ModelClueService.java @@ -173,7 +173,7 @@ public class ModelClueService extends ServiceImpl { for (ModelClue modelClue : modelClues) { modelClue.setModelId(modelId); modelClue.setCreateTime(LocalDateTime.now()); - SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, modelClue.getInvolveDepartId())); + SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, modelClue.getInvolveDepartId()).last("LIMIT 1")); if (supExternalDepart != null && supExternalDepart.getInternalShortName() != null && !supExternalDepart.getInternalShortName().isEmpty()) { modelClue.setInvolveDepartName(supExternalDepart.getInternalShortName()); modelClue.setInvolveDepartId(supExternalDepart.getInternalId()); @@ -226,7 +226,7 @@ public class ModelClueService extends ServiceImpl { + ",受理日期为" + getDateString(data.get("SLRQ")) + ",当前案件状态为“" + data.get("AJZTmc") + "”,已经超过" + "30" - + "日仍未受理。案件详情:" + thingDesc); + + "日仍未受理。" + thingDesc); } else if (modelId == 3) { // 3号模型:执法办案场所登记时长超时问题监督模型 if (data.get("lksj") != null && !data.get("lksj").equals("")) { modelClue.setThingDesc("姓名" + data.get("xm") @@ -242,6 +242,14 @@ public class ModelClueService extends ServiceImpl { + "登记进入" + data.get("csmc") + ",没有离开时间。"); } + } else if (modelId == 10) { + modelClue.setThingDesc("该" + data.get("AJBZmc") + + "案件编号为" + data.get("AJBH") + + ",报案日期为" + getDateString(data.get("BARQ")) + + ",受理日期为" + getDateString(data.get("SLRQ")) + + ",当前案件状态为“" + data.get("AJZTmc") + + "”,已经超过" + "3" + + "日仍未受理。"); } break; } @@ -263,7 +271,7 @@ public class ModelClueService extends ServiceImpl { } List jjdModelClues = new ArrayList<>(); for (Map data : jjdmaps) { - SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, data.get("involve_depart_id"))); + SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, data.get("involve_depart_id")).last("LIMIT 1")); if (supExternalDepart != null && supExternalDepart.getExternalId() != null && supExternalDepart.getExternalName() != null && supExternalDepart.getInternalId() != null && supExternalDepart.getLevel() != null && supExternalDepart.getPid() != null) { ModelClue modelClue = new ModelClue(); modelClue.setData(JSONObject.toJSONString(data)); @@ -283,7 +291,7 @@ public class ModelClueService extends ServiceImpl { mergeModelClues(jjdModelClues4, jjdModelClues3, 1); List zfqymModelClues = new ArrayList<>(); for (Map data : zfqymaps) { - SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, data.get("involve_depart_id"))); + SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getExternalId, data.get("involve_depart_id")).last("LIMIT 1")); if (supExternalDepart != null && supExternalDepart.getExternalId() != null && supExternalDepart.getExternalName() != null && supExternalDepart.getInternalId() != null && supExternalDepart.getLevel() != null && supExternalDepart.getPid() != null) { ModelClue modelClue = new ModelClue(); modelClue.setData(JSONObject.toJSONString(data)); @@ -427,7 +435,7 @@ public class ModelClueService extends ServiceImpl { } } if (!found) { - SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getInternalId, modelClue2.getParentId())); + SupExternalDepart supExternalDepart = supExternalDepartMapper.selectOne(new LambdaQueryWrapper().eq(SupExternalDepart::getInternalId, modelClue2.getParentId()).last("LIMIT 1")); if (supExternalDepart != null) { ModelClue newModelClue = new ModelClue(); newModelClue.setData(modelClue2.getData());