diff --git a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html index fd86684e..677a0dc8 100644 --- a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html +++ b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/registration/registration.html @@ -401,7 +401,7 @@ formatter:function (value,row,index) { for (i = 0; i < reson.length; i++) { if (reson[i].dictValue == row.checkCss) { - return "
"+ reson[i].dictLabel +"
"; + return ""+ reson[i].dictLabel +""; } } } @@ -525,7 +525,7 @@ formatter:function (value,row,index) { for (i = 0; i < reson.length; i++) { if (reson[i].dictValue == row.checkCss) { - return "
"+ reson[i].dictLabel +"
"; + return ""+ reson[i].dictLabel +""; } } } diff --git a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementCheckStatisticsController.java b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementCheckStatisticsController.java index c38f9464..38010ed0 100644 --- a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementCheckStatisticsController.java +++ b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementCheckStatisticsController.java @@ -89,7 +89,7 @@ public class EnforcementCheckStatisticsController extends BaseController { System.out.println(enterpriseStreetList); enforcementCheckStatisticsService.excelExport2(response,enterpriseStreetList,enterpriseAddress); } - //http://localhost:85/enforcementCheckStatistics/queryAllList/2024-8-26/2024-8-28 + //http://10.132.108.3:85/enforcementCheckStatistics/queryAllList/2024-8-24/2024-11-20 @GetMapping ("/queryAllList/{startTime}/{endTime}") @ResponseBody public void queryAllList(HttpServletResponse response, @PathVariable String startTime, @PathVariable String endTime) throws ParseException {//以企业维度统计 diff --git a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementRegistrationController.java b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementRegistrationController.java index 9f42fced..074ba98d 100644 --- a/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementRegistrationController.java +++ b/lib/EmergencyService/zdxtLawEnforcementCodeService/src/main/java/com/zdxt/code/controller/EnforcementRegistrationController.java @@ -12,6 +12,7 @@ import java.util.function.Function; import java.util.stream.Collectors; import com.zdxt.auth.project.system.dept.service.IDeptService; +import com.zdxt.auth.project.system.dict.mapper.DictDataMapper; import com.zdxt.auth.project.system.dict.service.IDictDataService; import com.zdxt.code.domain.EnforceRegCount; import com.zdxt.code.domain.EnterpriseLawEnforcement; @@ -62,6 +63,8 @@ public class EnforcementRegistrationController extends BaseController private IDeptService iDeptService; @Autowired private EnforcementCheckStatisticsService enforcementCheckStatisticsService; + @Autowired + private DictDataMapper dictDataMapper; @RequiresPermissions("code:registration:view") @GetMapping() @@ -711,34 +714,33 @@ public class EnforcementRegistrationController extends BaseController enforcementCheckStatistics.setNowTime(new Date()); List enforcementCheckStatisticsList=enforcementCheckStatisticsService.selectAllStatisticsList(enforcementCheckStatistics); List inOrderList=new ArrayList<>(); - Collections.addAll(inOrderList,"福田区","罗湖区","盐田区","南山区","宝安区","龙岗区","龙华区", - "坪山区","光明区","大鹏新区","深汕特别合作区"); + List dictDataListQY=dictDataMapper.selectDictDataByType("address_type"); + /*Collections.addAll(inOrderList,"福田区","罗湖区","盐田区","南山区","宝安区","龙岗区","龙华区", + "坪山区","光明区","大鹏新区","深汕特别合作区");*/ + for(DictData d:dictDataListQY){ + inOrderList.add(d.getDictLabel()); + } Map> enforcementCheckStatisticsMap=new HashMap<>(); for(int i=0;i e1=enforcementCheckStatisticsList.stream().filter(item->item.getEnterpriseAddress().contains(area)).collect(Collectors.toList()); - List e1=new ArrayList<>(); - if(area.equals("光明区")){//光明区特殊处理 - //e1 = enforcementCheckStatisticsList.stream().collect(Collectors.groupingBy(item -> ((item.getEnterpriseAddress().contains(area)||(item.getEnterpriseAddress().contains("光明新区")))? area : "其他"))); - e1=enforcementCheckStatisticsList.stream().filter(item->(item.getEnterpriseAddress().contains(area)||item.getEnterpriseAddress().contains("光明新区"))).collect(Collectors.toList()); - }else { - // e1 = enforcementCheckStatisticsList.stream().collect(Collectors.groupingBy(item -> (item.getEnterpriseAddress().contains(area)? area : "其他"))); - e1=enforcementCheckStatisticsList.stream().filter(item->item.getEnterpriseAddress().contains(area)).collect(Collectors.toList()); - } + List e1=enforcementCheckStatisticsList.stream().filter(item -> item.getEnterpriseAddress().startsWith("深圳市" + area.substring(0, area.indexOf("区")) + "区") || item.getEnterpriseAddress().startsWith("深圳市" + area.substring(0, area.indexOf("区")) + "新区")).collect(Collectors.toList()); enforcementCheckStatisticsMap.put(area,e1); } //将地址不属于各个区的筛出来放入执法记录map - List qt=enforcementCheckStatisticsList.stream().filter(item->!( - item.getEnterpriseAddress().contains("福田区")||item.getEnterpriseAddress().contains("罗湖区")|| - item.getEnterpriseAddress().contains("盐田区")||item.getEnterpriseAddress().contains("南山区")|| - item.getEnterpriseAddress().contains("宝安区")||item.getEnterpriseAddress().contains("龙岗区")|| - item.getEnterpriseAddress().contains("龙华区")||item.getEnterpriseAddress().contains("坪山区")|| - item.getEnterpriseAddress().contains("大鹏新区")||item.getEnterpriseAddress().contains("深汕特别合作区")|| - item.getEnterpriseAddress().contains("光明区")||item.getEnterpriseAddress().contains("光明新区"))) - .collect(Collectors.toList()); + List qt=enforcementCheckStatisticsList.stream().filter(item->!qyqtMake(inOrderList,item.getEnterpriseAddress())).collect(Collectors.toList()); enforcementCheckStatisticsMap.put("其他",qt); List enterpriseStreet=enforcementCheckStatisticsService.selectEnterpriseStreetList(); inOrderList.add("其他"); enforcementCheckStatisticsService.ZFJDM(httpServletResponse,enforcementCheckStatistics,inOrderList,enforcementCheckStatisticsMap,enterpriseStreet); } + + public Boolean qyqtMake(List strings,String s){ + for (String string : strings) { + if (s.startsWith("深圳市" + string.substring(0, string.indexOf("区")) + "区")||s.startsWith("深圳市" + string.substring(0, string.indexOf("区")) + "新区")) { + return true; + } + } + return false; + } }