|
|
|
|
@ -162,10 +162,8 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
public void generate(Integer modelId) { |
|
|
|
|
Model model = modelMapper.selectById(modelId); |
|
|
|
|
List<ModelClue> modelClues = new ArrayList<>(); |
|
|
|
|
if (!Objects.isNull(model)) { |
|
|
|
|
if (model.getModelSql() != null) { |
|
|
|
|
modelClues.addAll(getModelClueBySql(model.getModelSql(), modelId)); |
|
|
|
|
} |
|
|
|
|
if (!Objects.isNull(model) && model.getModelSql() != null) { |
|
|
|
|
modelClues.addAll(getModelClueBySql(model.getModelSql(), modelId)); |
|
|
|
|
} |
|
|
|
|
if (!modelClues.isEmpty()) { |
|
|
|
|
for (ModelClue modelClue : modelClues) { |
|
|
|
|
@ -219,7 +217,7 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
modelClue.setInvolveDepartId(supExternalDepart.getInternalId()); |
|
|
|
|
} |
|
|
|
|
setPerson(modelId, modelClue, data); |
|
|
|
|
generateZFBAThingDesc(modelId, modelClue, data); |
|
|
|
|
generateThingDesc(modelId, modelClue, data); |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
@ -229,83 +227,49 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
|
|
|
|
|
private void setPerson(Integer modelId, ModelClue modelClue, Map<String, Object> data) { |
|
|
|
|
if (modelId == 3) { // 执法区域人员表
|
|
|
|
|
if (data.get("bar1") != null && !data.get("bar1").equals("")) { |
|
|
|
|
if (data.get("bar2") != null && !data.get("bar2").equals("")) { |
|
|
|
|
modelClue.setInvolvePoliceName(data.get("bar1") + "," + data.get("bar2")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceName((String) data.get("bar1")); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
if (data.get("bar2") != null && !data.get("bar2").equals("")) { |
|
|
|
|
modelClue.setInvolvePoliceName((String) data.get("bar2")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
if (data.get("bar1jh") != null && !data.get("bar1jh").equals("")) { |
|
|
|
|
if (data.get("bar2jh") != null && !data.get("bar2jh").equals("")) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(data.get("bar1jh") + "," + data.get("bar2jh")); |
|
|
|
|
String bar1 = (String) data.get("bar1"); |
|
|
|
|
String bar2 = (String) data.get("bar2"); |
|
|
|
|
String involvePoliceName = (bar1 != null && !bar1.isEmpty() && bar2 != null && !bar2.isEmpty()) |
|
|
|
|
? bar1 + "," + bar2 |
|
|
|
|
: (bar1 != null && !bar1.isEmpty()) ? bar1 |
|
|
|
|
: (bar2 != null && !bar2.isEmpty()) ? bar2 : "无数据"; |
|
|
|
|
modelClue.setInvolvePoliceName(involvePoliceName); |
|
|
|
|
String bar1jh = (String) data.get("bar1jh"); |
|
|
|
|
String bar2jh = (String) data.get("bar2jh"); |
|
|
|
|
if (bar1jh != null && !bar1jh.isEmpty()) { |
|
|
|
|
if (bar2jh != null && !bar2jh.isEmpty()) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(bar1jh + "," + bar2jh); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) data.get("bar1jh")); |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(bar1jh); |
|
|
|
|
} |
|
|
|
|
} else if (bar2jh != null && !bar2jh.isEmpty()) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(bar2jh); |
|
|
|
|
} else { |
|
|
|
|
if (data.get("bar2jh") != null && !data.get("bar2jh").equals("")) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) data.get("bar2jh")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
} |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
if (modelId == 10 || modelId == 11 || modelId == 12 || modelId == 13 || modelId == 14 || modelId == 15) { // 案件基本信息表
|
|
|
|
|
Map<String, Object> bar1; |
|
|
|
|
Map<String, Object> bar2; |
|
|
|
|
if (data.get("BAR1ID") != null && !data.get("BAR1ID").equals("")) { |
|
|
|
|
bar1 = modelClueDataMapper.selectBAR((String) data.get("BAR1ID")); |
|
|
|
|
if (data.get("BAR2ID") != null && !data.get("BAR2ID").equals("")) { |
|
|
|
|
bar2 = modelClueDataMapper.selectBAR((String) data.get("BAR2ID")); |
|
|
|
|
if (bar1 != null) { |
|
|
|
|
if (bar2 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(bar1.get("JH") + "," + bar2.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName(bar1.get("XM") + "," + bar2.get("XM")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar1.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar1.get("XM")); |
|
|
|
|
} |
|
|
|
|
} else if (bar2 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar2.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar2.get("XM")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
if (bar1 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar1.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar1.get("XM")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
String bar1Id = (String) data.get("BAR1ID"); |
|
|
|
|
String bar2Id = (String) data.get("BAR2ID"); |
|
|
|
|
Map<String, Object> bar1 = bar1Id != null && !bar1Id.isEmpty() ? modelClueDataMapper.selectBAR(bar1Id) : null; |
|
|
|
|
Map<String, Object> bar2 = bar2Id != null && !bar2Id.isEmpty() ? modelClueDataMapper.selectBAR(bar2Id) : null; |
|
|
|
|
if (bar1 != null && bar2 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo(bar1.get("JH") + "," + bar2.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName(bar1.get("XM") + "," + bar2.get("XM")); |
|
|
|
|
} else if (bar1 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar1.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar1.get("XM")); |
|
|
|
|
} else if (bar2 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar2.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar2.get("XM")); |
|
|
|
|
} else { |
|
|
|
|
if (data.get("bar2jh") != null && !data.get("bar2jh").equals("")) { |
|
|
|
|
bar2 = modelClueDataMapper.selectBAR((String) data.get("BAR2ID")); |
|
|
|
|
if (bar2 != null) { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo((String) bar2.get("JH")); |
|
|
|
|
modelClue.setInvolvePoliceName((String) bar2.get("XM")); |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
modelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
modelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private static void generateZFBAThingDesc(Integer modelId, ModelClue modelClue, Map<String, Object> data) { |
|
|
|
|
private static void generateThingDesc(Integer modelId, ModelClue modelClue, Map<String, Object> data) { |
|
|
|
|
if (modelId == 1) { // 1号模型:行政、刑事案件受理30天仍未立案问题监督模型
|
|
|
|
|
String thingDesc = modelClue.getThingDesc(); |
|
|
|
|
modelClue.setThingDesc("该" + data.get("AJBZmc") |
|
|
|
|
@ -378,13 +342,8 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private static String getAjbh(Map<String, Object> data) { |
|
|
|
|
String AJBH; |
|
|
|
|
if (data.get("AJBH") == null || data.get("AJBH").equals("")) { |
|
|
|
|
AJBH = "空"; |
|
|
|
|
} else { |
|
|
|
|
AJBH = (String) data.get("AJBH"); |
|
|
|
|
} |
|
|
|
|
return AJBH; |
|
|
|
|
String ajbh = (String) data.get("AJBH"); |
|
|
|
|
return ajbh == null || ajbh.isEmpty() ? "无数据" : ajbh; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private List<ModelClue> getModelCluesForModel4(String param, List<ModelClue> modelClues) { |
|
|
|
|
@ -530,38 +489,32 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
if (modelClue.get("bar1xm") != null) { |
|
|
|
|
if (modelClue.get("bar2xm") != null) { |
|
|
|
|
newModelClue.setInvolvePoliceName(modelClue.get("bar1xm") + "、" + modelClue.get("bar2xm")); |
|
|
|
|
} else { |
|
|
|
|
if (modelClue.get("bar1xm") != null && modelClue.get("bar2xm") != null) { |
|
|
|
|
newModelClue.setInvolvePoliceName(modelClue.get("bar1xm") + "、" + modelClue.get("bar2xm")); |
|
|
|
|
} else if (modelClue.get("bar1xm") != null){ |
|
|
|
|
newModelClue.setInvolvePoliceName((String) modelClue.get("bar1xm")); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
if (modelClue.get("bar2xm") != null) { |
|
|
|
|
} else if (modelClue.get("bar2xm") != null){ |
|
|
|
|
newModelClue.setInvolvePoliceName((String) modelClue.get("bar2xm")); |
|
|
|
|
} else { |
|
|
|
|
} else { |
|
|
|
|
newModelClue.setInvolvePoliceName("无数据"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
Map<String, Object> bar1 = modelClueDataMapper.selectBAR((String) modelClue.get("bar1id")); |
|
|
|
|
Map<String, Object> bar2 = modelClueDataMapper.selectBAR((String) modelClue.get("bar2id")); |
|
|
|
|
if (bar1 != null && bar1.get("JH") != null) { |
|
|
|
|
if (bar2 != null && bar2.get("JH") != null) { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo(bar1.get("JH") + "、" + bar2.get("JH")); |
|
|
|
|
} else { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo((String) bar1.get("JH")); |
|
|
|
|
} |
|
|
|
|
String jh1 = bar1 == null ? null : (String) bar1.get("JH"); |
|
|
|
|
String jh2 = bar2 == null ? null : (String) bar2.get("JH"); |
|
|
|
|
if (jh1 != null && jh2 != null) { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo(jh1 + "、" + jh2); |
|
|
|
|
} else if (jh1 != null) { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo(jh1); |
|
|
|
|
} else if (jh2 != null) { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo(jh2); |
|
|
|
|
} else { |
|
|
|
|
if (bar2 != null && bar2.get("JH") != null) { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo((String) bar2.get("JH")); |
|
|
|
|
} else { |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
} |
|
|
|
|
newModelClue.setInvolvePoliceEmpNo("无数据"); |
|
|
|
|
} |
|
|
|
|
newModelClue.setData(JSONObject.toJSONString(modelClue)); |
|
|
|
|
newModelClue.setStatus(0); |
|
|
|
|
newModelClue.setThingDesc("在" + params.get(0) + "到" + params.get(1) + "之间," |
|
|
|
|
+ (String) modelClue.get("xm") |
|
|
|
|
+ modelClue.get("xm") |
|
|
|
|
+ "(身份证号:" + modelClue.get("sfzh") + ")的取保次数为" |
|
|
|
|
+ sfzhMap.get((String) modelClue.get("sfzh")) + "次,大于2次,属于多次取保异常数据。"); |
|
|
|
|
modelClues.add(newModelClue); |
|
|
|
|
@ -675,23 +628,15 @@ public class ModelClueService extends ServiceImpl<ModelClueMapper, ModelClue> {
|
|
|
|
|
List<ModelClue> modelClues1 = modelClueDataMapper.selectDataByDynamicSql(preSql + "盗" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 骗"); |
|
|
|
|
List<ModelClue> modelClues2 = modelClueDataMapper.selectDataByDynamicSql(preSql + "骗" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 强奸"); |
|
|
|
|
List<ModelClue> modelClues3 = modelClueDataMapper.selectDataByDynamicSql(preSql + "强奸" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 抢"); |
|
|
|
|
List<ModelClue> modelClues4 = modelClueDataMapper.selectDataByDynamicSql(preSql + "抢" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 10岁"); |
|
|
|
|
List<ModelClue> modelClues5 = modelClueDataMapper.selectDataByDynamicSql(preSql + "10岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 11岁"); |
|
|
|
|
List<ModelClue> modelClues6 = modelClueDataMapper.selectDataByDynamicSql(preSql + "11岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 12岁"); |
|
|
|
|
List<ModelClue> modelClues7 = modelClueDataMapper.selectDataByDynamicSql(preSql + "12岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 13岁"); |
|
|
|
|
List<ModelClue> modelClues8 = modelClueDataMapper.selectDataByDynamicSql(preSql + "13岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 14岁"); |
|
|
|
|
List<ModelClue> modelClues9 = modelClueDataMapper.selectDataByDynamicSql(preSql + "14岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 15岁"); |
|
|
|
|
List<ModelClue> modelClues10 = modelClueDataMapper.selectDataByDynamicSql(preSql + "15岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 16岁"); |
|
|
|
|
List<ModelClue> modelClues11 = modelClueDataMapper.selectDataByDynamicSql(preSql + "16岁" + postSql); |
|
|
|
|
System.out.println("模型2开始查询数据库 未成年"); |
|
|
|
|
List<ModelClue> modelClues12 = modelClueDataMapper.selectDataByDynamicSql(preSql + "未成年" + postSql); |
|
|
|
|
|