diff --git a/src/main/java/cn/com/tenlion/commonpopulation/service/floatingpopulation/impl/FloatingPopulationServiceImpl.java b/src/main/java/cn/com/tenlion/commonpopulation/service/floatingpopulation/impl/FloatingPopulationServiceImpl.java index b3818d1..2f5df2f 100644 --- a/src/main/java/cn/com/tenlion/commonpopulation/service/floatingpopulation/impl/FloatingPopulationServiceImpl.java +++ b/src/main/java/cn/com/tenlion/commonpopulation/service/floatingpopulation/impl/FloatingPopulationServiceImpl.java @@ -373,13 +373,13 @@ public class FloatingPopulationServiceImpl extends DefaultBaseService implements areaList.add(totalMap); }else{ List areaDTOS = mongoAreaService.listByParentId(areaParentId); - //int totalPeopleNum = 0; - final AtomicInteger totalPeopleNum = new AtomicInteger(0); + int totalPeopleNum = 0; + //final AtomicInteger totalPeopleNum = new AtomicInteger(0); List areaDTOS1 = Collections.synchronizedList(areaDTOS); //初始时间 long startTime = System.currentTimeMillis(); - areaDTOS1.parallelStream().forEach(item -> { - //for (AreaDTO item : areaDTOS) { + //areaDTOS1.parallelStream().forEach(item -> { + for (AreaDTO item : areaDTOS) { Map temp = new HashMap<>(16); Map queryParam = new HashMap<>(16); // 查询是否存在子节点 @@ -405,9 +405,9 @@ public class FloatingPopulationServiceImpl extends DefaultBaseService implements Integer counts = floatingPopulationDao.countFloatingPopulationNew(queryParam); temp.put("areaPeopleNum", counts); areaList.add(temp); - //totalPeopleNum += counts; - totalPeopleNum.addAndGet(counts); - }); + totalPeopleNum += counts; + //totalPeopleNum.addAndGet(counts); + }//); // Collections.sort(areaList, new Comparator>() { // @Override // public int compare(Map o1, Map o2) { @@ -421,8 +421,8 @@ public class FloatingPopulationServiceImpl extends DefaultBaseService implements totalMap.put("areaParentId", ""); totalMap.put("areaCode" , parentDTO.getAreaCode()); totalMap.put("areaName", "合计"); - // totalMap.put("areaPeopleNum", totalPeopleNum); - totalMap.put("areaPeopleNum", totalPeopleNum.get()); + totalMap.put("areaPeopleNum", totalPeopleNum); + // totalMap.put("areaPeopleNum", totalPeopleNum.get()); areaList.add(totalMap); /*测试程序部分*/ long endTime = System.currentTimeMillis(); diff --git a/src/main/resources/mybatis/mapper/commonpopulation/basepopulationinfo/basepopulationinfo-mapper.xml b/src/main/resources/mybatis/mapper/commonpopulation/basepopulationinfo/basepopulationinfo-mapper.xml index 36bc18d..bcbc055 100644 --- a/src/main/resources/mybatis/mapper/commonpopulation/basepopulationinfo/basepopulationinfo-mapper.xml +++ b/src/main/resources/mybatis/mapper/commonpopulation/basepopulationinfo/basepopulationinfo-mapper.xml @@ -308,6 +308,12 @@ t1.full_name LIKE CONCAT('%', #{keywords}, '%') ) + + AND t1.political_status = #{politicalStatus} + + + AND t1.nation = #{nation} + AND t1.full_name LIKE CONCAT('%', #{fullName}, '%') diff --git a/src/main/resources/mybatis/mapper/commonpopulation/floatingpopulation/floatingpopulation-mapper.xml b/src/main/resources/mybatis/mapper/commonpopulation/floatingpopulation/floatingpopulation-mapper.xml index 9d6d5e3..3233307 100644 --- a/src/main/resources/mybatis/mapper/commonpopulation/floatingpopulation/floatingpopulation-mapper.xml +++ b/src/main/resources/mybatis/mapper/commonpopulation/floatingpopulation/floatingpopulation-mapper.xml @@ -385,6 +385,12 @@ t1.id_card_number LIKE CONCAT('%', #{keywords}, '%') ) + + AND t1.political_status = #{politicalStatus} + + + AND t1.nation = #{nation} + AND t1.full_name LIKE CONCAT('%', #{fullName}, '%') diff --git a/src/main/resources/static/route/basepopulationinfo/list-basepopulationinfo.html b/src/main/resources/static/route/basepopulationinfo/list-basepopulationinfo.html index c68e47e..4808b9f 100644 --- a/src/main/resources/static/route/basepopulationinfo/list-basepopulationinfo.html +++ b/src/main/resources/static/route/basepopulationinfo/list-basepopulationinfo.html @@ -347,6 +347,8 @@ idCardNumber: $('#idCardNumber').val(), telephone: $('#telephone').val(), areaParentId : areaParentId[areaParentId.length -1], + politicalStatus: $("#politicalStatus").val(), + nation: $("#nation").val(), type: type, areaCode : areaCode == "gridId" ? "" : areaCode, gridId: gridId ? gridId : "" diff --git a/src/main/resources/static/route/floatingpopulation/list-floatingpopulation.html b/src/main/resources/static/route/floatingpopulation/list-floatingpopulation.html index 3006f9e..839c8aa 100644 --- a/src/main/resources/static/route/floatingpopulation/list-floatingpopulation.html +++ b/src/main/resources/static/route/floatingpopulation/list-floatingpopulation.html @@ -138,7 +138,7 @@ base: 'assets/layuiadmin/' }).extend({ index: 'lib/index' - }).use(['index', 'table', 'laydate', 'common', 'laytpl'], function() { + }).use(['index', 'table', 'laydate', 'common', 'laytpl', 'form'], function() { var $ = layui.$; var $win = $(window); var table = layui.table; @@ -149,6 +149,7 @@ var idCardNumberSearchValue = ''; var areaParentId = ['']; var areaCode = ''; + var form = layui.form; $('#left-card-div').height($win.height() - 30); $('#left-card-div').css('overflow', 'auto'); @@ -357,6 +358,8 @@ fullName: $('#fullName').val(), idCardNumber: $('#idCardNumber').val(), telephone: $('#telephone').val(), + politicalStatus: $("#politicalStatus").val(), + nation: $("#nation").val(), areaParentId : areaParentId[areaParentId.length -1], areaCode : areaCode == "gridId" ? "" : areaCode, gridId: gridId ? gridId : ""