Prechádzať zdrojové kódy

fix 新增登录非admin账户维护状态,通过配置文件控制,修复新增一个人员删除后,居住地址会在该人员再次新增的时候出现,新增新的变更接口,一次人员查询接口,修改行政区域的id不是String不走索引的问题

tjf 3 rokov pred
rodič
commit
02b91b52ae

+ 10 - 0
boman-auth/src/main/java/com/boman/auth/service/SysLoginService.java

@@ -4,6 +4,7 @@ import com.boman.common.redis.service.RedisService;
 import com.boman.domain.dto.AjaxResult;
 import com.boman.domain.form.LoginBody;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.beans.factory.annotation.Value;
 import org.springframework.stereotype.Component;
 import com.boman.domain.constant.Constants;
 import com.boman.domain.constant.UserConstants;
@@ -35,6 +36,9 @@ public class SysLoginService {
     @Autowired
     private RedisService redisService;
 
+    @Value("${upkeep}")
+    private Boolean upKeep;
+
     /**
      * 登录
      */
@@ -85,6 +89,9 @@ public class SysLoginService {
             throw new BaseException("用户不存在/密码错误");
         }
 
+        if (upKeep && !"admin".equals(username)){
+            throw new BaseException("当前正在维护");
+        }
         remoteLogService.saveLogininfor(username, Constants.LOGIN_SUCCESS, "登录成功");
         return userInfo;
     }
@@ -119,6 +126,9 @@ public class SysLoginService {
             remoteLogService.saveLogininfor(userName, Constants.LOGIN_FAIL, "用户已停用,请联系管理员");
             throw new BaseException("对不起,您的账号:" + userName + " 已停用");
         }
+        if (upKeep && !"admin".equals(userName)){
+            throw new BaseException("当前正在维护");
+        }
         remoteLogService.saveLogininfor(userName, Constants.LOGIN_SUCCESS, "登录成功");
         redisService.setCacheObject(form.getUuid(),form.getPhone());
         return R.ok();

+ 8 - 0
boman-auth/src/main/resources/META-INF/additional-spring-configuration-metadata.json

@@ -0,0 +1,8 @@
+{
+  "properties": [
+    {
+      "name": "upkeep",
+      "type": "java.lang.String",
+      "description": "Description for upkeep."
+  }
+] }

+ 1 - 0
boman-auth/src/main/resources/bootstrap.yml

@@ -36,3 +36,4 @@ justauth:
     type: redis
     prefix: 'SOCIAL::STATE::'
     timeout: 1h
+upkeep: false

Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 0 - 0
boman-common/boman-common-security/src/main/java/com/boman/common/security/service/TokenService.java


+ 1 - 1
boman-web-core/src/main/java/com/boman/web/core/controller/CzrkController.java

@@ -173,7 +173,7 @@ public class CzrkController extends BaseController {
 
 
     /**
-     * 变更接口,接收status 状态值,id_card 身份证号码
+     * 变更接口,接收status 状态值和id
      * @param czrk
      * @return
      */

+ 6 - 6
boman-web-core/src/main/java/com/boman/web/core/controller/SysRegionController.java

@@ -37,7 +37,7 @@ public class SysRegionController {
     private SysRegionMapper sysRegionMapper;
 
 
-    @PostMapping("/insert")
+    //@PostMapping("/insert")
     public void insertSysRegion() throws IOException {
 
         System.out.println("开始爬取");
@@ -113,7 +113,7 @@ public class SysRegionController {
         /*    if ( "安阳市".equals(name)|| "鹤壁市".equals(name)|| "新乡市".equals(name)||"焦作市".equals(name)) {*/
                 SysRegion region = new SysRegion();
                 region.setId(Long.valueOf(code));
-                region.setPid(i);
+                region.setPid(String.valueOf(i));
                 region.setName(name);
                 // 这里的排序写死,层级树设置为第一层。
                 // 因为我的业务逻辑只拿宁波市的乡镇信息。
@@ -138,7 +138,7 @@ public class SysRegionController {
         Elements countryAll = document.select(".countytr");
 
         // 这里的sort没有从0开始增加,是因为市下的第一级为市辖区,该级下无子级,用不着采集。所以直接跳过。
-        long sort = 0;
+        long sort = -1;
 
         for (Element countrytr : countryAll) {
             sort++;
@@ -158,7 +158,7 @@ public class SysRegionController {
                     }else {
                         region.setId(Long.valueOf( cityCode+ "123456"+sort));
                     }
-                    region.setPid(Long.valueOf(cityCode));
+                    region.setPid(cityCode);
                     region.setName(name);
                     region.setTreeLevel(2);
                     region.setLeaf(1);
@@ -196,7 +196,7 @@ public class SysRegionController {
 
             SysRegion region = new SysRegion();
             region.setId(Long.valueOf(code));
-            region.setPid(Long.valueOf(countryCode));
+            region.setPid(countryCode);
             region.setName(name);
             region.setTreeLevel(3);
             region.setLeaf(1);
@@ -236,7 +236,7 @@ public class SysRegionController {
 
                 SysRegion region = new SysRegion();
                 region.setId(Long.valueOf(code));
-                region.setPid(Long.valueOf(townCode));
+                region.setPid(townCode);
                 region.setName(name);
                 region.setTreeLevel(4);
                 region.setLeaf(1);

+ 16 - 16
boman-web-core/src/main/java/com/boman/web/core/controller/TestController.java

@@ -87,9 +87,9 @@ public class TestController {
                                 } else if (sysRegions.size() > 1) {
                                     for (SysRegion sysRegion : sysRegions) {
                                         if (sysRegion != null) {
-                                            Long pid = sysRegion.getPid();
+                                            String pid = sysRegion.getPid();
                                             Long regionId = czrk.getRegionId();
-                                            if (regionId != null && regionId.equals(pid)) {
+                                            if (regionId != null && String.valueOf(regionId).equals(pid)) {
                                                 //说明是这个镇
                                                 czrk.setVillageTowns(sysRegion.getName());
                                                 czrk.setVillageTownsId(sysRegion.getAreaId());
@@ -110,9 +110,9 @@ public class TestController {
                                     } else if (sysRegionsVillage.size() > 1) {
                                         for (SysRegion sysRegion : sysRegionsVillage) {
                                             if (sysRegion != null) {
-                                                Long pid = sysRegion.getPid();
+                                                String pid = sysRegion.getPid();
                                                 Long villageTownsId = czrk.getVillageTownsId();
-                                                if (villageTownsId != null && villageTownsId.equals(pid)) {
+                                                if (villageTownsId != null && String.valueOf(villageTownsId).equals(pid)) {
                                                     //说明是这个镇下面的村
                                                     czrk.setVillage(sysRegion.getName());
                                                     czrk.setVillageId(sysRegion.getAreaId());
@@ -210,9 +210,9 @@ public class TestController {
                                 if (sysRegions.size() > 0) {
                                     for (SysRegion sysRegion : sysRegions) {
                                         if (sysRegion != null) {
-                                            Long pid = sysRegion.getPid();
+                                            String pid = sysRegion.getPid();
                                             if (pid != null) {
-                                                if ("340882000000".equals(pid.toString())) {
+                                                if ("340882000000".equals(pid)) {
                                                     czrk.setVillageTownsId(sysRegion.getAreaId());
                                                     czrk.setVillageTowns(villageTowns);
                                                 }
@@ -397,9 +397,9 @@ public class TestController {
                                 } else if (sysRegions.size() > 1) {
                                     for (SysRegion sysRegion : sysRegions) {
                                         if (sysRegion != null) {
-                                            Long pid = sysRegion.getPid();
+                                            String pid = sysRegion.getPid();
                                             Long villageTownsId = czrk.getVillageTownsId();
-                                            if (villageTownsId != null && villageTownsId.equals(pid)) {
+                                            if (villageTownsId != null && String.valueOf(villageTownsId).equals(pid)) {
                                                 //说明是这个镇下面的村
                                                 czrk.setVillage(sysRegion.getName());
                                                 czrk.setVillageId(sysRegion.getAreaId());
@@ -437,9 +437,9 @@ public class TestController {
                                                     } else if (sysRegions.size() > 1) {
                                                         for (SysRegion sysRegion : sysRegions) {
                                                             if (sysRegion != null) {
-                                                                Long pid = sysRegion.getPid();
+                                                                String pid = sysRegion.getPid();
                                                                 Long villageTownsId = czrk.getVillageTownsId();
-                                                                if (villageTownsId != null && villageTownsId.equals(pid)) {
+                                                                if (villageTownsId != null && String.valueOf(villageTownsId).equals(pid)) {
                                                                     //说明是这个镇下面的村
                                                                     czrk.setVillage(sysRegion.getName());
                                                                     czrk.setVillageId(sysRegion.getAreaId());
@@ -467,9 +467,9 @@ public class TestController {
                                             } else if (sysRegions.size() > 1) {
                                                 for (SysRegion sysRegion : sysRegions) {
                                                     if (sysRegion != null) {
-                                                        Long pid = sysRegion.getPid();
+                                                        String pid = sysRegion.getPid();
                                                         Long villageTownsId = czrk.getVillageTownsId();
-                                                        if (villageTownsId != null && villageTownsId.equals(pid)) {
+                                                        if (villageTownsId != null && String.valueOf(villageTownsId).equals(pid)) {
                                                             //说明是这个镇下面的村
                                                             czrk.setVillage(sysRegion.getName());
                                                             czrk.setVillageId(sysRegion.getAreaId());
@@ -555,8 +555,8 @@ public class TestController {
                                     }
                                     if (sysRegions.size() > 1) {
                                         for (SysRegion sysRegion : sysRegions) {
-                                            Long pid = sysRegion.getPid();
-                                            if ("340882000000".equals(pid.toString())) {
+                                            String pid = sysRegion.getPid();
+                                            if ("340882000000".equals(pid)) {
                                                 String name = sysRegion.getName();
                                                 Long areaId = sysRegion.getAreaId();
                                                 czrkJzdz.setTown(name);
@@ -581,8 +581,8 @@ public class TestController {
                                     }
                                     if (sysRegions.size() > 1) {
                                         for (SysRegion sysRegion : sysRegions) {
-                                            Long pid = sysRegion.getPid();
-                                            if (czrkJzdz.getTownId().equals(pid)) {
+                                            String pid = sysRegion.getPid();
+                                            if (String.valueOf(czrkJzdz.getTownId()).equals(pid)) {
                                                 String name = sysRegion.getName();
                                                 Long areaId = sysRegion.getAreaId();
                                                 czrkJzdz.setVillage(name);

+ 3 - 3
boman-web-core/src/main/java/com/boman/web/core/domain/SysRegion.java

@@ -24,7 +24,7 @@ public class SysRegion implements Serializable {
      * 上级ID,一级为0
      */
 
-    private Long pid;
+    private String pid;
 
     /**
      * 名称
@@ -66,11 +66,11 @@ public class SysRegion implements Serializable {
         this.id = id;
     }
 
-    public Long getPid() {
+    public String getPid() {
         return pid;
     }
 
-    public void setPid(Long pid) {
+    public void setPid(String pid) {
         this.pid = pid;
     }
 

+ 2 - 0
boman-web-core/src/main/java/com/boman/web/core/mapper/CzrkJzdzMapper.java

@@ -66,6 +66,8 @@ import java.util.List;
 
     List<CzrkJzdz> listByIdCard(@Param("idCardList") List<String> idCardList);
 
+    List<CzrkJzdz> listByCzrkId(@Param("czrkId") Long czrkId);
+
     List<Long> listCzrkIdByTypeAreaIdUserName(@Param("type") int type, @Param("areaId") Long areaId, @Param("userName") String userName);
 
     int updateByIdCard(CzrkJzdz czrkJzdz);

+ 7 - 0
boman-web-core/src/main/java/com/boman/web/core/mapper/CzrkMapper.java

@@ -170,4 +170,11 @@ public interface CzrkMapper {
     Czrk selectCzrkByIdCard(String code);
 
     List<Czrk> selectLost();
+
+    /**
+     * 查询非正常人员列表(死亡,失踪)
+     * @param czrk
+     * @return
+     */
+    List<Czrk> unusualList(Czrk czrk);
 }

+ 12 - 0
boman-web-core/src/main/java/com/boman/web/core/service/czrk/CzrkJzdzServiceImpl.java

@@ -128,5 +128,17 @@ public class CzrkJzdzServiceImpl implements ICzrkJzdzService {
         return czrkJzdzMapper.updateHouseholdRegister(idCardList,hzCzrkJzdz);
     }
 
+    /**
+     * 根据czrdId查询对应的居住地址
+     * @param czrkId
+     * @return
+     */
+    @Override
+    public List<CzrkJzdz> listByCzrkId(Long czrkId) {
+        if (isEmpty(czrkId)) {
+            return Collections.emptyList();
+        }
 
+        return czrkJzdzMapper.listByCzrkId(czrkId);
+    }
 }

+ 19 - 3
boman-web-core/src/main/java/com/boman/web/core/service/czrk/CzrkServiceImpl.java

@@ -219,9 +219,9 @@ public class CzrkServiceImpl implements ICzrkService {
         startPage();
         long startTimeSql = System.currentTimeMillis();
         //todo 重新写个接口查询状态值 != 1的数据
-        List<Czrk> czrks = czrkMapper.listByRlryJzdz(czrk);
+        List<Czrk> czrks = czrkMapper.unusualList(czrk);
         long endTimeSql = System.currentTimeMillis() - startTimeSql;
-        log.info("执行查询居住地址的sql语句时间:" + endTimeSql + "ms");
+        log.info("执行查询异常人员sql语句时间:" + endTimeSql + "ms");
         packAddr(czrks);
         return czrks;
     }
@@ -632,7 +632,7 @@ public class CzrkServiceImpl implements ICzrkService {
             czrk.setHzIdCard(hzCzrk.getIdCard());
         }
 
-        List<CzrkJzdz> czrkJzdzList = czrkJzdzService.listByIdCard(Collections.singletonList(czrk.getIdCard()));
+        List<CzrkJzdz> czrkJzdzList = czrkJzdzService.listByCzrkId(czrk.getId());
         czrk.setCzrkJzdzList(czrkJzdzList);
         //todo 重新计算年龄
         String birthday = czrk.getBirthday();
@@ -802,8 +802,23 @@ public class CzrkServiceImpl implements ICzrkService {
         return childCount == czrkJzdzList.size() ? AjaxResult.success() : AjaxResult.error();
     }
 
+    /**
+     * 小程序接口统计认领人员
+     * @param provinceId
+     * @param cityId
+     * @param regionId
+     * @param townId
+     * @param villageId
+     * @param idCard
+     * @param userName
+     * @param queryType
+     * @param houseType
+     * @param isConfirm
+     * @return
+     */
     @Override
     public JSONObject stsByApplet(Long provinceId, Long cityId, Long regionId, Long townId, Long villageId, String idCard, String userName, String queryType, String houseType, String isConfirm) {
+        //todo 需要增加用户权限,根据sys_dept表中area_id来进行关联
         Long areaId = null;
         int type = 0, yrl = 0, wrl = 0;
         if (ObjectUtils.isNotEmpty(provinceId)) {
@@ -825,6 +840,7 @@ public class CzrkServiceImpl implements ICzrkService {
 
         if (Czrk.HJ.equals(queryType)) {
             // 户籍
+            //todo areaId不能是Long类型改为String 不然走不上索引
             yrl = czrkMapper.stsByYrl(type, areaId, idCard, userName, houseType, isConfirm);
             wrl = czrkMapper.stsByWrl(type, areaId, idCard, userName, houseType, isConfirm);
         } else {

+ 2 - 0
boman-web-core/src/main/java/com/boman/web/core/service/czrk/ICzrkJzdzService.java

@@ -70,4 +70,6 @@ public interface ICzrkJzdzService {
     int updateByCzrkId(CzrkJzdz czrkJzdz);
 
     int updateHouseholdRegister(List<String> idCardList, CzrkJzdz hzCzrkJzdz);
+
+    List<CzrkJzdz> listByCzrkId(Long czrkId);
 }

+ 5 - 0
boman-web-core/src/main/resources/mapper/CzrkJzdzMapper.xml

@@ -99,6 +99,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         </foreach>
     </select>
 
+    <select id="listByCzrkId" resultMap="CzrkJzdzResult">
+        <include refid="selectCzrkJzdzVo"/>
+        where czrk_id = #{czrkId}
+    </select>
+
     <insert id="insertCzrkJzdz" useGeneratedKeys="true" keyProperty="id">
         insert into czrk_jzdz
         <trim prefix="(" suffix=")" suffixOverrides=",">

+ 399 - 327
boman-web-core/src/main/resources/mapper/CzrkMapper.xml

@@ -1,98 +1,98 @@
 <?xml version="1.0" encoding="UTF-8" ?>
 <!DOCTYPE mapper
-PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
-"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.boman.web.core.mapper.CzrkMapper">
-    
+
     <resultMap type="com.boman.domain.Czrk" id="CzrkResult">
-        <result property="id"    column="id"    />
-        <result property="czrkJzdzId"    column="czrk_jzdz_id"    />
-        <result property="userName"    column="user_name"    />
-        <result property="gender"    column="gender"    />
-        <result property="age"    column="age"    />
-        <result property="birthday"    column="birthday"    />
-        <result property="deptId"    column="dept_id"    />
-        <result property="idCard"    column="id_card"    />
-        <result property="phoneNum"    column="phone_num"    />
-        <result property="code"    column="code"    />
-        <result property="houseType"    column="house_type"    />
-        <result property="rlr"    column="rlr"    />
-        <result property="rlrNike"    column="rlr_nike"    />
-        <result property="rlTime"    column="rl_time"    />
-        <result property="keyIndustries"    column="key_industries"    />
-        <result property="yhzgx"    column="yhzgx"    />
-        <result property="workUnit"    column="work_unit"    />
-        <result property="provinceId"    column="province_id"    />
-        <result property="province"    column="province"    />
-        <result property="cityId"    column="city_id"    />
-        <result property="city"    column="city"    />
-        <result property="regionId"    column="region_id"    />
-        <result property="isRl"    column="is_rl"    />
-        <result property="region"    column="region"    />
-        <result property="villageTownsId"    column="village_towns_id"    />
-        <result property="villageTowns"    column="village_towns"    />
-        <result property="villageId"    column="village_id"    />
-        <result property="village"    column="village"    />
-        <result property="villagerGroupId"    column="villager_group_id"    />
-        <result property="villagerGroup"    column="villager_group"    />
-        <result property="nowIn"    column="now_in"    />
-        <result property="remark"    column="remark"    />
-        <result property="gridId"    column="grid_id"    />
-        <result property="status"    column="status"    />
-        <result property="changUser"    column="chang_user"    />
-        <result property="changNikeUser"    column="chang_nike_user"    />
-        <result property="changUserTime"    column="chang_user_time"    />
-        <result property="isConfirm"    column="is_confirm"    />
-        <result property="confirmInfoUser"    column="confirm_info_user"    />
-        <result property="confirmInfoNikeUser"    column="confirm_info_nike_user"    />
-        <result property="confirmInfoUserTime"    column="confirm_info_user_time"    />
-        <result property="createBy"    column="create_by"    />
-        <result property="createTime"    column="create_time"    />
-        <result property="updateBy"    column="update_by"    />
-        <result property="updateTime"    column="update_time"    />
-        <result property="isDel"    column="is_del"    />
-        <result property="deleteReason"    column="delete_reason"    />
-        <collection  property="czrkJzdzList"   javaType="java.util.List"        resultMap="CzrkJzdzResult" />
+        <result property="id" column="id"/>
+        <result property="czrkJzdzId" column="czrk_jzdz_id"/>
+        <result property="userName" column="user_name"/>
+        <result property="gender" column="gender"/>
+        <result property="age" column="age"/>
+        <result property="birthday" column="birthday"/>
+        <result property="deptId" column="dept_id"/>
+        <result property="idCard" column="id_card"/>
+        <result property="phoneNum" column="phone_num"/>
+        <result property="code" column="code"/>
+        <result property="houseType" column="house_type"/>
+        <result property="rlr" column="rlr"/>
+        <result property="rlrNike" column="rlr_nike"/>
+        <result property="rlTime" column="rl_time"/>
+        <result property="keyIndustries" column="key_industries"/>
+        <result property="yhzgx" column="yhzgx"/>
+        <result property="workUnit" column="work_unit"/>
+        <result property="provinceId" column="province_id"/>
+        <result property="province" column="province"/>
+        <result property="cityId" column="city_id"/>
+        <result property="city" column="city"/>
+        <result property="regionId" column="region_id"/>
+        <result property="isRl" column="is_rl"/>
+        <result property="region" column="region"/>
+        <result property="villageTownsId" column="village_towns_id"/>
+        <result property="villageTowns" column="village_towns"/>
+        <result property="villageId" column="village_id"/>
+        <result property="village" column="village"/>
+        <result property="villagerGroupId" column="villager_group_id"/>
+        <result property="villagerGroup" column="villager_group"/>
+        <result property="nowIn" column="now_in"/>
+        <result property="remark" column="remark"/>
+        <result property="gridId" column="grid_id"/>
+        <result property="status" column="status"/>
+        <result property="changUser" column="chang_user"/>
+        <result property="changNikeUser" column="chang_nike_user"/>
+        <result property="changUserTime" column="chang_user_time"/>
+        <result property="isConfirm" column="is_confirm"/>
+        <result property="confirmInfoUser" column="confirm_info_user"/>
+        <result property="confirmInfoNikeUser" column="confirm_info_nike_user"/>
+        <result property="confirmInfoUserTime" column="confirm_info_user_time"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
+        <result property="isDel" column="is_del"/>
+        <result property="deleteReason" column="delete_reason"/>
+        <collection property="czrkJzdzList" javaType="java.util.List" resultMap="CzrkJzdzResult"/>
     </resultMap>
 
     <resultMap type="com.boman.domain.CzrkJzdz" id="CzrkJzdzResult">
-        <result property="provinceId"    column="province_id_jzdz"    />
-        <result property="province"    column="province_jzdz"    />
-        <result property="cityId"    column="city_id_jzdz"    />
-        <result property="city"    column="city_jzdz"    />
-        <result property="regionId"    column="region_id_jzdz"    />
-        <result property="region"    column="region_jzdz"    />
-        <result property="townId"    column="town_id_jzdz"    />
-        <result property="town"    column="town_jzdz"    />
-        <result property="villageId"    column="village_id_jzdz"    />
-        <result property="village"    column="village_jzdz"    />
-        <result property="nowIn"    column="now_in_jzdz"    />
+        <result property="provinceId" column="province_id_jzdz"/>
+        <result property="province" column="province_jzdz"/>
+        <result property="cityId" column="city_id_jzdz"/>
+        <result property="city" column="city_jzdz"/>
+        <result property="regionId" column="region_id_jzdz"/>
+        <result property="region" column="region_jzdz"/>
+        <result property="townId" column="town_id_jzdz"/>
+        <result property="town" column="town_jzdz"/>
+        <result property="villageId" column="village_id_jzdz"/>
+        <result property="village" column="village_jzdz"/>
+        <result property="nowIn" column="now_in_jzdz"/>
     </resultMap>
 
 
     <resultMap type="com.boman.domain.SysDept" id="SysDeptResult">
-        <id     property="id"     column="id"     />
-        <result property="parentId"   column="parent_id"   />
-        <result property="ancestors"  column="ancestors"   />
-        <result property="deptName"   column="dept_name"   />
-        <result property="orderNum"   column="order_num"   />
-        <result property="leader"     column="leader"      />
-        <result property="phone"      column="phone"       />
-        <result property="email"      column="email"       />
-        <result property="status"     column="status"      />
-        <result property="delFlag"    column="del_flag"    />
-        <result property="parentName" column="parent_name" />
-        <result property="num" column="num" />
-        <result property="createBy"   column="create_by"   />
-        <result property="createTime" column="create_time" />
-        <result property="updateBy"   column="update_by"   />
-        <result property="updateTime" column="update_time" />
+        <id property="id" column="id"/>
+        <result property="parentId" column="parent_id"/>
+        <result property="ancestors" column="ancestors"/>
+        <result property="deptName" column="dept_name"/>
+        <result property="orderNum" column="order_num"/>
+        <result property="leader" column="leader"/>
+        <result property="phone" column="phone"/>
+        <result property="email" column="email"/>
+        <result property="status" column="status"/>
+        <result property="delFlag" column="del_flag"/>
+        <result property="parentName" column="parent_name"/>
+        <result property="num" column="num"/>
+        <result property="createBy" column="create_by"/>
+        <result property="createTime" column="create_time"/>
+        <result property="updateBy" column="update_by"/>
+        <result property="updateTime" column="update_time"/>
     </resultMap>
 
     <resultMap type="com.boman.web.core.domain.ConfirmInfoUser" id="ConfrimInforUserResult">
-        <result property="confirmInfoUser"    column="confirm_info_user"    />
-        <result property="confirmInfoNikeUser"    column="confirm_info_nike_user"    />
-        <result property="czrkId"    column="czrk_id"    />
+        <result property="confirmInfoUser" column="confirm_info_user"/>
+        <result property="confirmInfoNikeUser" column="confirm_info_nike_user"/>
+        <result property="czrkId" column="czrk_id"/>
     </resultMap>
     <sql id="selectCzrkVo">
         select id, user_name, gender, age, birthday,dept_id, id_card, phone_num, code, house_type, rlr,rlr_nike, rl_time, yhzgx
@@ -101,9 +101,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
              , update_by, update_time, is_del, delete_reason,  is_rl, key_industries from czrk
     </sql>
 
-    <select id="listByRlry"  resultMap="CzrkResult">
-        select id, user_name, phone_num,dept_id, id_card, gender, province, city, region, village_towns, village, villager_group, grid_id
-        , house_type, update_by, code, rlr,rlr_nike, update_time, delete_reason, now_in,is_confirm,confirm_info_user,confirm_info_nike_user,confirm_info_user_time
+    <select id="listByRlry" resultMap="CzrkResult">
+        select id, user_name, phone_num,dept_id, id_card, gender, province, city, region, village_towns, village,
+        villager_group, grid_id
+        , house_type, update_by, code, rlr,rlr_nike, update_time, delete_reason,
+        now_in,is_confirm,confirm_info_user,confirm_info_nike_user,confirm_info_user_time
         from czrk
         <where>
             <!-- 已认领 -->
@@ -114,35 +116,35 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             </if>
             <if test="params.startAge != null  and params.startAge != ''">and age &gt;= #{params.startAge}</if>
             <if test="params.endAge != null  and params.endAge != ''">and age &lt;= #{params.endAge}</if>
-            <if test="gender != null  and gender != ''"> and gender = #{gender}</if>
-            <if test="age != null "> and age = #{age}</if>
-            <if test="birthday != null "> and birthday = #{birthday}</if>
-            <if test="idCard != null  and idCard != ''"> and id_card = #{idCard}</if>
-            <if test="phoneNum != null  and phoneNum != ''"> and phone_num = #{phoneNum}</if>
-            <if test="code != null  and code != ''"> and code = #{code}</if>
-            <if test="houseType != null  and houseType != ''"> and house_type = #{houseType}</if>
-            <if test="rlr != null  and rlr != ''"> and rlr = #{rlr}</if>
-            <if test="rlTime != null "> and rl_time = #{rlTime}</if>
-            <if test="yhzgx != null  and yhzgx != ''"> and yhzgx = #{yhzgx}</if>
-            <if test="workUnit != null  and workUnit != ''"> and work_unit = #{workUnit}</if>
-            <if test="provinceId != null  and provinceId != ''"> and province_id = #{provinceId}</if>
-            <if test="province != null  and province != ''"> and province = #{province}</if>
-            <if test="cityId != null  and cityId != ''"> and city_id = #{cityId}</if>
-            <if test="city != null  and city != ''"> and city = #{city}</if>
-            <if test="regionId != null  and regionId != ''"> and region_id = #{regionId}</if>
-            <if test="region != null  and region != ''"> and region = #{region}</if>
-            <if test="villageTownsId != null  and villageTownsId != ''"> and village_towns_id = #{villageTownsId}</if>
-            <if test="villageTowns != null  and villageTowns != ''"> and village_towns = #{villageTowns}</if>
-            <if test="villageId != null  and villageId != ''"> and village_id = #{villageId}</if>
-            <if test="village != null  and village != ''"> and village = #{village}</if>
-        <!--    <if test="villagerGroupId != null  and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
-            <if test="villagerGroup != null  and villagerGroup != ''"> and villager_group = #{villagerGroup}</if>-->
-            <if test="nowIn != null  and nowIn != ''"> and now_in = #{nowIn}</if>
-            <if test="status != null  and status != ''"> and status = #{status}</if>
-            <if test="isConfirm != null  and isConfirm != ''"> and is_confirm = #{isConfirm}</if>
-            <if test="isDel != null  and isDel != ''"> and is_del = #{isDel}</if>
-            <if test="deleteReason != null  and deleteReason != ''"> and delete_reason = #{deleteReason}</if>
-            <if test="gridId != null  and gridId != ''"> and grid_id = #{gridId}</if>
+            <if test="gender != null  and gender != ''">and gender = #{gender}</if>
+            <if test="age != null ">and age = #{age}</if>
+            <if test="birthday != null ">and birthday = #{birthday}</if>
+            <if test="idCard != null  and idCard != ''">and id_card = #{idCard}</if>
+            <if test="phoneNum != null  and phoneNum != ''">and phone_num = #{phoneNum}</if>
+            <if test="code != null  and code != ''">and code = #{code}</if>
+            <if test="houseType != null  and houseType != ''">and house_type = #{houseType}</if>
+            <if test="rlr != null  and rlr != ''">and rlr = #{rlr}</if>
+            <if test="rlTime != null ">and rl_time = #{rlTime}</if>
+            <if test="yhzgx != null  and yhzgx != ''">and yhzgx = #{yhzgx}</if>
+            <if test="workUnit != null  and workUnit != ''">and work_unit = #{workUnit}</if>
+            <if test="provinceId != null  and provinceId != ''">and province_id = #{provinceId}</if>
+            <if test="province != null  and province != ''">and province = #{province}</if>
+            <if test="cityId != null  and cityId != ''">and city_id = #{cityId}</if>
+            <if test="city != null  and city != ''">and city = #{city}</if>
+            <if test="regionId != null  and regionId != ''">and region_id = #{regionId}</if>
+            <if test="region != null  and region != ''">and region = #{region}</if>
+            <if test="villageTownsId != null  and villageTownsId != ''">and village_towns_id = #{villageTownsId}</if>
+            <if test="villageTowns != null  and villageTowns != ''">and village_towns = #{villageTowns}</if>
+            <if test="villageId != null  and villageId != ''">and village_id = #{villageId}</if>
+            <if test="village != null  and village != ''">and village = #{village}</if>
+            <!--    <if test="villagerGroupId != null  and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
+                <if test="villagerGroup != null  and villagerGroup != ''"> and villager_group = #{villagerGroup}</if>-->
+            <if test="nowIn != null  and nowIn != ''">and now_in = #{nowIn}</if>
+            <if test="status != null  and status != ''">and status = #{status}</if>
+            <if test="isConfirm != null  and isConfirm != ''">and is_confirm = #{isConfirm}</if>
+            <if test="isDel != null  and isDel != ''">and is_del = #{isDel}</if>
+            <if test="deleteReason != null  and deleteReason != ''">and delete_reason = #{deleteReason}</if>
+            <if test="gridId != null  and gridId != ''">and grid_id = #{gridId}</if>
             <if test="deptIdList != null and deptIdList.size() > 0">
                 and dept_id in
                 <foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
@@ -159,9 +161,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         order by create_time DESC
     </select>
 
-    <select id="listByRlryJzdz"  resultMap="CzrkResult">
-        select c.id, c.user_name, c.phone_num,c.dept_id, c.id_card, c.gender, c.province, c.city, c.region, c.village_towns, c.village, c.villager_group, c.grid_id
-        , c.house_type, c.update_by, c.code, c.rlr,c.rlr_nike, c.update_time, c.delete_reason, c.now_in,c.is_confirm,c.confirm_info_user,c.confirm_info_nike_user,c.confirm_info_user_time
+    <select id="listByRlryJzdz" resultMap="CzrkResult">
+        select c.id, c.user_name, c.phone_num,c.dept_id, c.id_card, c.gender, c.province, c.city, c.region,
+        c.village_towns, c.village, c.villager_group, c.grid_id
+        , c.house_type, c.update_by, c.code, c.rlr,c.rlr_nike, c.update_time, c.delete_reason,
+        c.now_in,c.is_confirm,c.confirm_info_user,c.confirm_info_nike_user,c.confirm_info_user_time
         from czrk c left join czrk_jzdz z on c.id =z.czrk_id
         <where>
             <!-- 已认领 -->
@@ -172,34 +176,34 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             </if>
             <if test="params.startAge != null  and params.startAge != ''">and c.age &gt;= #{params.startAge}</if>
             <if test="params.endAge != null  and params.endAge != ''">and c.age &lt;= #{params.endAge}</if>
-            <if test="gender != null  and gender != ''"> and c.gender = #{gender}</if>
-            <if test="birthday != null "> and c.birthday = #{birthday}</if>
-            <if test="idCard != null  and idCard != ''"> and c.id_card = #{idCard}</if>
-            <if test="phoneNum != null  and phoneNum != ''"> and c.phone_num = #{phoneNum}</if>
-            <if test="code != null  and code != ''"> and c.code = #{code}</if>
-            <if test="houseType != null  and houseType != ''"> and c.house_type = #{houseType}</if>
-            <if test="rlr != null  and rlr != ''"> and c.rlr = #{rlr}</if>
-            <if test="rlTime != null "> and c.rl_time = #{rlTime}</if>
-            <if test="yhzgx != null  and yhzgx != ''"> and c.yhzgx = #{yhzgx}</if>
-            <if test="workUnit != null  and workUnit != ''"> and c.work_unit = #{workUnit}</if>
-            <if test="provinceId != null  and provinceId != ''"> and c.province_id = #{provinceId}</if>
-            <if test="province != null  and province != ''"> and c.province = #{province}</if>
-            <if test="cityId != null  and cityId != ''"> and c.city_id = #{cityId}</if>
-            <if test="city != null  and city != ''"> and c.city = #{city}</if>
-            <if test="regionId != null  and regionId != ''"> and c.region_id = #{regionId}</if>
-            <if test="region != null  and region != ''"> and c.region = #{region}</if>
-            <if test="villageTownsId != null  and villageTownsId != ''"> and c.village_towns_id = #{villageTownsId}</if>
-            <if test="villageTowns != null  and villageTowns != ''"> and c.village_towns = #{villageTowns}</if>
-            <if test="villageId != null  and villageId != ''"> and c.village_id = #{villageId}</if>
-            <if test="village != null  and village != ''"> and c.village = #{village}</if>
+            <if test="gender != null  and gender != ''">and c.gender = #{gender}</if>
+            <if test="birthday != null ">and c.birthday = #{birthday}</if>
+            <if test="idCard != null  and idCard != ''">and c.id_card = #{idCard}</if>
+            <if test="phoneNum != null  and phoneNum != ''">and c.phone_num = #{phoneNum}</if>
+            <if test="code != null  and code != ''">and c.code = #{code}</if>
+            <if test="houseType != null  and houseType != ''">and c.house_type = #{houseType}</if>
+            <if test="rlr != null  and rlr != ''">and c.rlr = #{rlr}</if>
+            <if test="rlTime != null ">and c.rl_time = #{rlTime}</if>
+            <if test="yhzgx != null  and yhzgx != ''">and c.yhzgx = #{yhzgx}</if>
+            <if test="workUnit != null  and workUnit != ''">and c.work_unit = #{workUnit}</if>
+            <if test="provinceId != null  and provinceId != ''">and c.province_id = #{provinceId}</if>
+            <if test="province != null  and province != ''">and c.province = #{province}</if>
+            <if test="cityId != null  and cityId != ''">and c.city_id = #{cityId}</if>
+            <if test="city != null  and city != ''">and c.city = #{city}</if>
+            <if test="regionId != null  and regionId != ''">and c.region_id = #{regionId}</if>
+            <if test="region != null  and region != ''">and c.region = #{region}</if>
+            <if test="villageTownsId != null  and villageTownsId != ''">and c.village_towns_id = #{villageTownsId}</if>
+            <if test="villageTowns != null  and villageTowns != ''">and c.village_towns = #{villageTowns}</if>
+            <if test="villageId != null  and villageId != ''">and c.village_id = #{villageId}</if>
+            <if test="village != null  and village != ''">and c.village = #{village}</if>
             <!--    <if test="villagerGroupId != null  and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
                 <if test="villagerGroup != null  and villagerGroup != ''"> and villager_group = #{villagerGroup}</if>-->
-            <if test="nowIn != null  and nowIn != ''"> and c.now_in = #{nowIn}</if>
-            <if test="status != null  and status != ''"> and c.status = #{status}</if>
-            <if test="isConfirm != null  and isConfirm != ''"> and c.is_confirm = #{isConfirm}</if>
-            <if test="isDel != null  and isDel != ''"> and c.is_del = #{isDel}</if>
-            <if test="deleteReason != null  and deleteReason != ''"> and c.delete_reason = #{deleteReason}</if>
-            <if test="gridId != null  and gridId != ''"> and c.grid_id = #{gridId}</if>
+            <if test="nowIn != null  and nowIn != ''">and c.now_in = #{nowIn}</if>
+            <if test="status != null  and status != ''">and c.status = #{status}</if>
+            <if test="isConfirm != null  and isConfirm != ''">and c.is_confirm = #{isConfirm}</if>
+            <if test="isDel != null  and isDel != ''">and c.is_del = #{isDel}</if>
+            <if test="deleteReason != null  and deleteReason != ''">and c.delete_reason = #{deleteReason}</if>
+            <if test="gridId != null  and gridId != ''">and c.grid_id = #{gridId}</if>
             <if test="deptIdList != null and deptIdList.size() > 0">
                 and c.dept_id in
                 <foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
@@ -212,40 +216,40 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                     #{idCard}
                 </foreach>
             </if>
-            <if test="czrkJzdz.provinceId != null"> and z.province_id = #{czrkJzdz.provinceId}</if>
-            <if test="czrkJzdz.cityId != null"> and z.city_id = #{czrkJzdz.cityId}</if>
-            <if test="czrkJzdz.regionId != null"> and z.region_id = #{czrkJzdz.regionId}</if>
-            <if test="czrkJzdz.townId != null"> and z.town_id = #{czrkJzdz.townId}</if>
-            <if test="czrkJzdz.villageId != null"> and z.village_id = #{czrkJzdz.villageId}</if>
+            <if test="czrkJzdz.provinceId != null">and z.province_id = #{czrkJzdz.provinceId}</if>
+            <if test="czrkJzdz.cityId != null">and z.city_id = #{czrkJzdz.cityId}</if>
+            <if test="czrkJzdz.regionId != null">and z.region_id = #{czrkJzdz.regionId}</if>
+            <if test="czrkJzdz.townId != null">and z.town_id = #{czrkJzdz.townId}</if>
+            <if test="czrkJzdz.villageId != null">and z.village_id = #{czrkJzdz.villageId}</if>
 
         </where>
         order by c.create_time DESC
     </select>
 
-    <select id="listByRlryRel"  resultType="com.boman.domain.Czrk">
+    <select id="listByRlryRel" resultType="com.boman.domain.Czrk">
         SELECT
-            czrk.id,
-            ANY_VALUE(czrk.user_name) userName,
-            ANY_VALUE(czrk.phone_num) phoneNum,
-            ANY_VALUE(czrk.id_card) idCard,
-            ANY_VALUE(czrk.gender) gender,
-            ANY_VALUE(czrk.province) province,
-            ANY_VALUE(czrk.is_rl) isRl,
-            ANY_VALUE(czrk.city) city,
-            ANY_VALUE(czrk.region) region,
-            ANY_VALUE(czrk.house_type) houseType,
-            ANY_VALUE(czrk.update_by) updateBy,
-            ANY_VALUE(czrk. CODE) CODE,
-            ANY_VALUE(czrk.rlr) rlr,
-            ANY_VALUE(czrk.update_time) updateTime,
-            ANY_VALUE(czrk.delete_reason) deleteReason,
-            ANY_VALUE(czrk.now_in) nowIn,
-            ANY_VALUE(jzdz.province) provinceXjd,
-            ANY_VALUE(jzdz.city) cityXjd,
-            ANY_VALUE(jzdz.region) regionXjd,
-            ANY_VALUE(jzdz.town) villageTownsXjd,
-            ANY_VALUE(jzdz.village) villageXjd,
-            ANY_VALUE(jzdz.now_in) domicile
+        czrk.id,
+        ANY_VALUE(czrk.user_name) userName,
+        ANY_VALUE(czrk.phone_num) phoneNum,
+        ANY_VALUE(czrk.id_card) idCard,
+        ANY_VALUE(czrk.gender) gender,
+        ANY_VALUE(czrk.province) province,
+        ANY_VALUE(czrk.is_rl) isRl,
+        ANY_VALUE(czrk.city) city,
+        ANY_VALUE(czrk.region) region,
+        ANY_VALUE(czrk.house_type) houseType,
+        ANY_VALUE(czrk.update_by) updateBy,
+        ANY_VALUE(czrk. CODE) CODE,
+        ANY_VALUE(czrk.rlr) rlr,
+        ANY_VALUE(czrk.update_time) updateTime,
+        ANY_VALUE(czrk.delete_reason) deleteReason,
+        ANY_VALUE(czrk.now_in) nowIn,
+        ANY_VALUE(jzdz.province) provinceXjd,
+        ANY_VALUE(jzdz.city) cityXjd,
+        ANY_VALUE(jzdz.region) regionXjd,
+        ANY_VALUE(jzdz.town) villageTownsXjd,
+        ANY_VALUE(jzdz.village) villageXjd,
+        ANY_VALUE(jzdz.now_in) domicile
         from czrk
         left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
         <where>
@@ -258,41 +262,45 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             </if>
             <if test="params.startAge != null  and params.startAge != ''">and czrk.age &gt;= #{params.startAge}</if>
             <if test="params.endAge != null  and params.endAge != ''">and czrk.age &lt;= #{params.endAge}</if>
-            <if test="gender != null  and gender != ''"> and czrk.gender = #{gender}</if>
-            <if test="age != null "> and czrk.age = #{age}</if>
-            <if test="birthday != null "> and czrk.birthday = #{birthday}</if>
-            <if test="idCard != null  and idCard != ''"> and czrk.id_card = #{idCard}</if>
-            <if test="phoneNum != null  and phoneNum != ''"> and czrk.phone_num = #{phoneNum}</if>
-            <if test="code != null  and code != ''"> and czrk.code = #{code}</if>
-            <if test="houseType != null  and houseType != ''"> and czrk.house_type = #{houseType}</if>
-            <if test="rlr != null  and rlr != ''"> and czrk.rlr = #{rlr}</if>
-            <if test="rlTime != null "> and czrk.rl_time = #{rlTime}</if>
-            <if test="yhzgx != null  and yhzgx != ''"> and czrk.yhzgx = #{yhzgx}</if>
-            <if test="workUnit != null  and workUnit != ''"> and czrk.work_unit = #{workUnit}</if>
-            <if test="provinceId != null  and provinceId != ''"> and czrk.province_id = #{provinceId}</if>
-
-            <if test="provinceIdXjd != null  and provinceIdXjd != ''"> and jzdz.province_id = #{provinceId}</if>
-            <if test="cityIdXjd != null  and cityIdXjd != ''"> and jzdz.city_id = #{cityIdXjd}</if>
-            <if test="regionIdXjd != null  and regionIdXjd != ''"> and jzdz.region_id = #{regionIdXjd}</if>
-            <if test="villageTownsIdXjd != null  and villageTownsIdXjd != ''"> and jzdz.town_id = #{villageTownsIdXjd}</if>
-            <if test="villageIdXjd != null  and villageIdXjd != ''"> and jzdz.village_id = #{villageIdXjd}</if>
-
-            <if test="province != null  and province != ''"> and czrk.province = #{province}</if>
-            <if test="cityId != null  and cityId != ''"> and czrk.city_id = #{cityId}</if>
-            <if test="city != null  and city != ''"> and czrk.city = #{city}</if>
-            <if test="regionId != null  and regionId != ''"> and czrk.region_id = #{regionId}</if>
-            <if test="region != null  and region != ''"> and czrk.region = #{region}</if>
-            <if test="villageTownsId != null  and villageTownsId != ''"> and czrk.village_towns_id = #{villageTownsId}</if>
-            <if test="villageTowns != null  and villageTowns != ''"> and czrk.village_towns = #{villageTowns}</if>
-            <if test="villageId != null  and villageId != ''"> and czrk.village_id = #{villageId}</if>
-            <if test="village != null  and village != ''"> and czrk.village = #{village}</if>
-            <if test="villagerGroupId != null  and villagerGroupId != ''"> and czrk.villager_group_id = #{villagerGroupId}</if>
-            <if test="villagerGroup != null  and villagerGroup != ''"> and czrk.villager_group = #{villagerGroup}</if>
-            <if test="nowIn != null  and nowIn != ''"> and czrk.now_in = #{nowIn}</if>
-            <if test="status != null  and status != ''"> and czrk.status = #{status}</if>
-            <if test="isDel != null  and isDel != ''"> and czrk.is_del = #{isDel}</if>
-            <if test="deleteReason != null  and deleteReason != ''"> and czrk.delete_reason = #{deleteReason}</if>
-            <if test="gridId != null  and gridId != ''"> and czrk.grid_id = #{gridId}</if>
+            <if test="gender != null  and gender != ''">and czrk.gender = #{gender}</if>
+            <if test="age != null ">and czrk.age = #{age}</if>
+            <if test="birthday != null ">and czrk.birthday = #{birthday}</if>
+            <if test="idCard != null  and idCard != ''">and czrk.id_card = #{idCard}</if>
+            <if test="phoneNum != null  and phoneNum != ''">and czrk.phone_num = #{phoneNum}</if>
+            <if test="code != null  and code != ''">and czrk.code = #{code}</if>
+            <if test="houseType != null  and houseType != ''">and czrk.house_type = #{houseType}</if>
+            <if test="rlr != null  and rlr != ''">and czrk.rlr = #{rlr}</if>
+            <if test="rlTime != null ">and czrk.rl_time = #{rlTime}</if>
+            <if test="yhzgx != null  and yhzgx != ''">and czrk.yhzgx = #{yhzgx}</if>
+            <if test="workUnit != null  and workUnit != ''">and czrk.work_unit = #{workUnit}</if>
+            <if test="provinceId != null  and provinceId != ''">and czrk.province_id = #{provinceId}</if>
+
+            <if test="provinceIdXjd != null  and provinceIdXjd != ''">and jzdz.province_id = #{provinceId}</if>
+            <if test="cityIdXjd != null  and cityIdXjd != ''">and jzdz.city_id = #{cityIdXjd}</if>
+            <if test="regionIdXjd != null  and regionIdXjd != ''">and jzdz.region_id = #{regionIdXjd}</if>
+            <if test="villageTownsIdXjd != null  and villageTownsIdXjd != ''">and jzdz.town_id = #{villageTownsIdXjd}
+            </if>
+            <if test="villageIdXjd != null  and villageIdXjd != ''">and jzdz.village_id = #{villageIdXjd}</if>
+
+            <if test="province != null  and province != ''">and czrk.province = #{province}</if>
+            <if test="cityId != null  and cityId != ''">and czrk.city_id = #{cityId}</if>
+            <if test="city != null  and city != ''">and czrk.city = #{city}</if>
+            <if test="regionId != null  and regionId != ''">and czrk.region_id = #{regionId}</if>
+            <if test="region != null  and region != ''">and czrk.region = #{region}</if>
+            <if test="villageTownsId != null  and villageTownsId != ''">and czrk.village_towns_id = #{villageTownsId}
+            </if>
+            <if test="villageTowns != null  and villageTowns != ''">and czrk.village_towns = #{villageTowns}</if>
+            <if test="villageId != null  and villageId != ''">and czrk.village_id = #{villageId}</if>
+            <if test="village != null  and village != ''">and czrk.village = #{village}</if>
+            <if test="villagerGroupId != null  and villagerGroupId != ''">and czrk.villager_group_id =
+                #{villagerGroupId}
+            </if>
+            <if test="villagerGroup != null  and villagerGroup != ''">and czrk.villager_group = #{villagerGroup}</if>
+            <if test="nowIn != null  and nowIn != ''">and czrk.now_in = #{nowIn}</if>
+            <if test="status != null  and status != ''">and czrk.status = #{status}</if>
+            <if test="isDel != null  and isDel != ''">and czrk.is_del = #{isDel}</if>
+            <if test="deleteReason != null  and deleteReason != ''">and czrk.delete_reason = #{deleteReason}</if>
+            <if test="gridId != null  and gridId != ''">and czrk.grid_id = #{gridId}</if>
 
             <if test="deptIdList != null and deptIdList.size() > 0">
                 and czrk.dept_id in
@@ -304,7 +312,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         GROUP BY czrk.id ORDER BY czrk.update_time DESC
     </select>
 
-    <select id="listByXz"  resultMap="CzrkResult">
+    <select id="listByXz" resultMap="CzrkResult">
         select vi.id, vi.create_time, vi.update_time, vi.is_del, vi.update_by, vi.user_name, vi.phone_num, vi.id_card
         , vi.gender, vi.province, vi.city, vi.region, vi.now_in, vi.house_type, vi.update_by, vi.code
         from czrk vi
@@ -315,23 +323,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="villageTowns != null  and villageTowns != ''">
             and vi.village_towns = #{villageTowns}
         </if>
-        <if test="village != null  and village != ''"> and vi.village = #{village}</if>
-        <if test="villagerGroup != null  and villagerGroup != ''"> and vi.villager_group = #{villagerGroup}</if>
-        <if test="houseType != null  and houseType != ''"> and vi.house_type = #{houseType}</if>
-        <if test="province != null  and province != ''"> and vi.province = #{province}</if>
-        <if test="city != null  and city != ''"> and vi.city = #{city}</if>
-        <if test="region != null  and region != ''"> and vi.region = #{region}</if>
-        <if test="gender != null  and gender != ''"> and vi.gender = #{gender}</if>
-        <if test="idCard != null  and idCard != ''"> and vi.id_card like concat(#{idCard}, '%')</if>
-        <if test="phoneNum != null  and phoneNum != ''"> and vi.phone_num = #{phoneNum}</if>
+        <if test="village != null  and village != ''">and vi.village = #{village}</if>
+        <if test="villagerGroup != null  and villagerGroup != ''">and vi.villager_group = #{villagerGroup}</if>
+        <if test="houseType != null  and houseType != ''">and vi.house_type = #{houseType}</if>
+        <if test="province != null  and province != ''">and vi.province = #{province}</if>
+        <if test="city != null  and city != ''">and vi.city = #{city}</if>
+        <if test="region != null  and region != ''">and vi.region = #{region}</if>
+        <if test="gender != null  and gender != ''">and vi.gender = #{gender}</if>
+        <if test="idCard != null  and idCard != ''">and vi.id_card like concat(#{idCard}, '%')</if>
+        <if test="phoneNum != null  and phoneNum != ''">and vi.phone_num = #{phoneNum}</if>
         <!--<if test="params.startAge != null  and params.startAge != ''"> and vi.age &gt;= #{params.startAge}</if>
        <if test="params.endAge != null  and params.endAge != ''"> and vi.age &lt;= #{params.endAge}</if>-->
-        <if test="status != null  and status != ''"> and vi.status = #{status}</if>
-        <if test="code != null  and code != ''"> and vi.code = #{code}</if>
-        <if test="birthday != null  and birthday != ''"> and vi.birthday = #{birthday}</if>
-        <if test="workUnit != null  and workUnit != ''"> and vi.work_unit = #{workUnit}</if>
-        <if test="nowIn != null  and nowIn != ''"> and vi.now_in = #{nowIn}</if>
-        <if test="gridId != null  and gridId != ''"> and vi.grid_id = #{gridId}</if>
+        <if test="status != null  and status != ''">and vi.status = #{status}</if>
+        <if test="code != null  and code != ''">and vi.code = #{code}</if>
+        <if test="birthday != null  and birthday != ''">and vi.birthday = #{birthday}</if>
+        <if test="workUnit != null  and workUnit != ''">and vi.work_unit = #{workUnit}</if>
+        <if test="nowIn != null  and nowIn != ''">and vi.now_in = #{nowIn}</if>
+        <if test="gridId != null  and gridId != ''">and vi.grid_id = #{gridId}</if>
 
         <if test="deptIdList != null  and deptIdList.size() > 0">
             and vi.dept_id in
@@ -378,24 +386,24 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <if test="villageTowns != null  and villageTowns != ''">
             and vi.village_towns = #{villageTowns}
         </if>
-        <if test="village != null  and village != ''"> and vi.village = #{village}</if>
-        <if test="villagerGroup != null  and villagerGroup != ''"> and vi.villager_group = #{villagerGroup}</if>
-        <if test="houseType != null  and houseType != ''"> and vi.house_type = #{houseType}</if>
-        <if test="province != null  and province != ''"> and vi.province = #{province}</if>
-        <if test="city != null  and city != ''"> and vi.city = #{city}</if>
-        <if test="region != null  and region != ''"> and vi.region = #{region}</if>
-        <if test="userName != null  and userName != ''"> and vi.user_name like concat(#{userName}, '%')</if>
-        <if test="gender != null  and gender != ''"> and vi.gender = #{gender}</if>
-        <if test="idCard != null  and idCard != ''"> and vi.id_card like concat(#{idCard}, '%')</if>
-        <if test="phoneNum != null  and phoneNum != ''"> and vi.phone_num = #{phoneNum}</if>
+        <if test="village != null  and village != ''">and vi.village = #{village}</if>
+        <if test="villagerGroup != null  and villagerGroup != ''">and vi.villager_group = #{villagerGroup}</if>
+        <if test="houseType != null  and houseType != ''">and vi.house_type = #{houseType}</if>
+        <if test="province != null  and province != ''">and vi.province = #{province}</if>
+        <if test="city != null  and city != ''">and vi.city = #{city}</if>
+        <if test="region != null  and region != ''">and vi.region = #{region}</if>
+        <if test="userName != null  and userName != ''">and vi.user_name like concat(#{userName}, '%')</if>
+        <if test="gender != null  and gender != ''">and vi.gender = #{gender}</if>
+        <if test="idCard != null  and idCard != ''">and vi.id_card like concat(#{idCard}, '%')</if>
+        <if test="phoneNum != null  and phoneNum != ''">and vi.phone_num = #{phoneNum}</if>
         <!--<if test="params.startAge != null  and params.startAge != ''"> and vi.age &gt;= #{params.startAge}</if>
         <if test="params.endAge != null  and params.endAge != ''"> and vi.age &lt;= #{params.endAge}</if>-->
-        <if test="status != null  and status != ''"> and vi.status = #{status}</if>
-        <if test="code != null  and code != ''"> and vi.code = #{code}</if>
-        <if test="birthday != null  and birthday != ''"> and vi.birthday = #{birthday}</if>
-        <if test="workUnit != null  and workUnit != ''"> and vi.work_unit = #{workUnit}</if>
-        <if test="nowIn != null  and nowIn != ''"> and vi.now_in = #{nowIn}</if>
-        <if test="gridId != null  and gridId != ''"> and vi.grid_id = #{gridId}</if>
+        <if test="status != null  and status != ''">and vi.status = #{status}</if>
+        <if test="code != null  and code != ''">and vi.code = #{code}</if>
+        <if test="birthday != null  and birthday != ''">and vi.birthday = #{birthday}</if>
+        <if test="workUnit != null  and workUnit != ''">and vi.work_unit = #{workUnit}</if>
+        <if test="nowIn != null  and nowIn != ''">and vi.now_in = #{nowIn}</if>
+        <if test="gridId != null  and gridId != ''">and vi.grid_id = #{gridId}</if>
 
         <if test="deptIdList != null  and deptIdList.size() > 0">
             and vi.dept_id in
@@ -432,7 +440,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
     <select id="listByCode" resultMap="CzrkResult">
-        select vi.id, vi.user_name, vi.phone_num, vi.id_card, vi.gender, vi.province, vi.city, vi.region,vi.village_towns,vi.village,vi.villager_group, vi.now_in
+        select vi.id, vi.user_name, vi.phone_num, vi.id_card, vi.gender, vi.province, vi.city,
+        vi.region,vi.village_towns,vi.village,vi.villager_group, vi.now_in
         , vi.house_type, vi.update_by, vi.code, vi.rlr, vi.yhzgx
         from czrk vi
         <!--把户主放第一位-->
@@ -450,7 +459,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
 
-
     <select id="countCzrk" resultType="int">
         select count(vi.id)
         from czrk vi
@@ -499,7 +507,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
     <select id="listByCzXz1" resultType="com.boman.domain.Czrk">
-        SELECT 	ANY_VALUE(jzdz.id_card) idCard,
+        SELECT ANY_VALUE(jzdz.id_card) idCard,
         ANY_VALUE(jzdz.create_time) createTime from czrk_jzdz jzdz
         where jzdz.status = 'Y' and jzdz.create_time &gt;= #{startTime} and jzdz.create_time &lt;= #{endTime}
         <if test="deptIdList != null  and deptIdList.size() > 0">
@@ -585,7 +593,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 
     <select id="selectCzrkById" parameterType="Long" resultMap="CzrkResult">
         <include refid="selectCzrkVo"/>
-        where id = #{id}   and is_del = 'N' limit 1
+        where id = #{id} and is_del = 'N' limit 1
     </select>
 
 
@@ -610,7 +618,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <!-- 已认领 -->
         and vi.is_rl = '是'
         <if test="idCard != null  and idCard != ''">
-            and  vi.id_card = #{idCard}
+            and vi.id_card = #{idCard}
         </if>
         <if test="houseType != null  and houseType != ''">
             and vi.house_type = #{houseType}
@@ -619,7 +627,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             and vi.is_confirm = #{isConfirm}
         </if>
         <if test="userName != null  and userName != ''">
-            and  vi.user_name like concat(#{userName}, '%')
+            and vi.user_name like concat(#{userName}, '%')
         </if>
         <choose>
             <when test="type == 1">and vi.province_id = #{areaId}</when>
@@ -674,7 +682,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             and vi.is_confirm = #{isConfirm}
         </if>
         <if test="userName != null  and userName != ''">
-            and  vi.user_name like concat(#{userName}, '%')
+            and vi.user_name like concat(#{userName}, '%')
         </if>
         <choose>
             <when test="type == 1">and vi.province_id = #{areaId}</when>
@@ -686,7 +694,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
 
-    <insert id="insertCzrk"  useGeneratedKeys="true" keyProperty="id">
+    <insert id="insertCzrk" useGeneratedKeys="true" keyProperty="id">
         insert into czrk
         <trim prefix="(" suffix=")" suffixOverrides=",">
             <if test="userName != null">user_name,</if>
@@ -728,7 +736,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isDel != null and isDel != ''">is_del,</if>
             <if test="deleteReason != null">delete_reason,</if>
             create_time, update_time
-         </trim>
+        </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="userName != null">#{userName},</if>
             <if test="gender != null">#{gender},</if>
@@ -772,7 +780,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         </trim>
     </insert>
 
-    <update id="updateCzrk" >
+    <update id="updateCzrk">
         update czrk
         <trim prefix="SET" suffixOverrides=",">
             <if test="userName != null">user_name = #{userName},</if>
@@ -808,7 +816,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="status != null">status = #{status},</if>
             <if test="isConfirm != null and isConfirm != ''">is_confirm = #{isConfirm},</if>
             <if test="confirmInfoUser != null and confirmInfoUser != ''">confirm_info_user = #{confirmInfoUser},</if>
-            <if test="confirmInfoNikeUser != null and confirmInfoNikeUser != ''">confirm_info_nike_user = #{confirmInfoNikeUser},</if>
+            <if test="confirmInfoNikeUser != null and confirmInfoNikeUser != ''">confirm_info_nike_user =
+                #{confirmInfoNikeUser},
+            </if>
             <if test="confirmInfoUserTime != null ">confirm_info_user_time = #{confirmInfoUserTime},</if>
             <if test="createBy != null">create_by = #{createBy},</if>
             <if test="createTime != null">create_time = #{createTime},</if>
@@ -833,12 +843,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         where id = #{id}
     </update>
 
-<!--    <delete id="deleteCzrk" parameterType="String">-->
-<!--        delete from czrk where id in -->
-<!--        <foreach item="id" collection="array" open="(" separator="," close=")">-->
-<!--            #{id}-->
-<!--        </foreach>-->
-<!--    </delete>-->
+    <!--    <delete id="deleteCzrk" parameterType="String">-->
+    <!--        delete from czrk where id in -->
+    <!--        <foreach item="id" collection="array" open="(" separator="," close=")">-->
+    <!--            #{id}-->
+    <!--        </foreach>-->
+    <!--    </delete>-->
 
     <update id="deleteCzrk">
         update czrk
@@ -867,28 +877,31 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         where is_del = 'N' and code = #{czrk.code};
     </update>
 
-    <select id="findHjInfo"  resultMap="CzrkResult">
-        select c.id, c.user_name ,c.gender, c.birthday,c.age,c.code,c.phone_num,c.key_industries,c.province_id,c.province,c.city_id,c.city,c.region_id,c.region,c.village_towns_id,c.village_towns,c.village_id,c.village,c.villager_group_id,c.villager_group,
+    <select id="findHjInfo" resultMap="CzrkResult">
+        select c.id, c.user_name ,c.gender,
+        c.birthday,c.age,c.code,c.phone_num,c.key_industries,c.province_id,c.province,c.city_id,c.city,c.region_id,c.region,c.village_towns_id,c.village_towns,c.village_id,c.village,c.villager_group_id,c.villager_group,
         c.now_in,c.house_type,c.code,c.yhzgx,c.remark,
-        cj.province_id as province_id_jzdz,cj.province as province_jzdz,cj.city_id as city_id_jzdz,cj.city as city_jzdz,cj.region_id as region_id_jzdz,cj.region as region_jzdz,cj.town_id as town_id_jzdz,cj.town as town_jzdz,cj.village_id as village_id_jzdz,cj.village as village_jzdz,cj.now_in as now_in_jzdz
-         from czrk c left join czrk_jzdz cj on c.id_card = cj.id_card
+        cj.province_id as province_id_jzdz,cj.province as province_jzdz,cj.city_id as city_id_jzdz,cj.city as
+        city_jzdz,cj.region_id as region_id_jzdz,cj.region as region_jzdz,cj.town_id as town_id_jzdz,cj.town as
+        town_jzdz,cj.village_id as village_id_jzdz,cj.village as village_jzdz,cj.now_in as now_in_jzdz
+        from czrk c left join czrk_jzdz cj on c.id_card = cj.id_card
         <where>
             c.is_del = 'N'
             and cj.status = 'Y'
-            <if test="idCard != null and idCard != '' "> and c.id_card = #{idCard}</if>
+            <if test="idCard != null and idCard != '' ">and c.id_card = #{idCard}</if>
         </where>
     </select>
 
     <select id="stsByAppletCz" resultMap="CzrkResult">
         SELECT
-            czrk.id,
-            czrk.is_rl
+        czrk.id,
+        czrk.is_rl
         from czrk
         left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
         <where>
             czrk.is_del = 'N' and jzdz.status = 'Y'
             <if test="idCard != null  and idCard != ''">
-                and czrk.id_card  = #{idCard}
+                and czrk.id_card = #{idCard}
             </if>
             <if test="houseType != null  and houseType != ''">
                 and czrk.house_type = #{houseType}
@@ -897,7 +910,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                 and czrk.is_confirm = #{isConfirm}
             </if>
             <if test="userName != null  and userName != ''">
-                and  czrk.user_name like concat(#{userName}, '%')
+                and czrk.user_name like concat(#{userName}, '%')
             </if>
             <choose>
                 <when test="type == 1">and jzdz.province_id = #{areaId}</when>
@@ -907,18 +920,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
                 <when test="type == 5">and jzdz.village_id = #{areaId}</when>
             </choose>
 
-           <!-- <if test="provinceIdXjd != null  and provinceIdXjd != ''"> and jzdz.province_id = #{areaId}</if>
-            <if test="cityIdXjd != null  and cityIdXjd != ''"> and jzdz.city_id = #{areaId}</if>
-            <if test="regionIdXjd != null  and regionIdXjd != ''"> and jzdz.region_id = #{areaId}</if>
-            <if test="villageTownsIdXjd != null  and villageTownsIdXjd != ''"> and jzdz.town_id = #{areaId}</if>
-            <if test="villageIdXjd != null  and villageIdXjd != ''"> and jzdz.village_id = #{areaId}</if>-->
-
-           <!-- <if test="provinceId != null  and provinceId != ''"> and czrk.province_id = #{areaId}</if>
-            <if test="cityId != null  and cityId != ''"> and czrk.city_id = #{areaId}</if>
-            <if test="regionId != null  and regionId != ''"> and czrk.region_id = #{areaId}</if>
-            <if test="villageTownsId != null  and villageTownsId != ''"> and czrk.village_towns_id = #{areaId}</if>
-            <if test="villageId != null  and villageId != ''"> and czrk.village_id = #{areaId}</if>
-            <if test="villagerGroupId != null  and villagerGroupId != ''"> and czrk.villager_group_id = #{villagerGroupId}</if>-->
+            <!-- <if test="provinceIdXjd != null  and provinceIdXjd != ''"> and jzdz.province_id = #{areaId}</if>
+             <if test="cityIdXjd != null  and cityIdXjd != ''"> and jzdz.city_id = #{areaId}</if>
+             <if test="regionIdXjd != null  and regionIdXjd != ''"> and jzdz.region_id = #{areaId}</if>
+             <if test="villageTownsIdXjd != null  and villageTownsIdXjd != ''"> and jzdz.town_id = #{areaId}</if>
+             <if test="villageIdXjd != null  and villageIdXjd != ''"> and jzdz.village_id = #{areaId}</if>-->
+
+            <!-- <if test="provinceId != null  and provinceId != ''"> and czrk.province_id = #{areaId}</if>
+             <if test="cityId != null  and cityId != ''"> and czrk.city_id = #{areaId}</if>
+             <if test="regionId != null  and regionId != ''"> and czrk.region_id = #{areaId}</if>
+             <if test="villageTownsId != null  and villageTownsId != ''"> and czrk.village_towns_id = #{areaId}</if>
+             <if test="villageId != null  and villageId != ''"> and czrk.village_id = #{areaId}</if>
+             <if test="villagerGroupId != null  and villagerGroupId != ''"> and czrk.villager_group_id = #{villagerGroupId}</if>-->
         </where>
         GROUP BY czrk.id
     </select>
@@ -961,16 +974,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         GROUP BY czrk.id
     </select>
 
-     <select id="countByHjJs" resultType="int">
-         SELECT COUNT(DISTINCT(jzdz.id_card)) from czrk_jzdz jzdz
-         where jzdz.status = 'N' and jzdz.update_time &gt;= #{startTime} and jzdz.update_time &lt;= #{endTime}
-         <!-- SELECT czrk.id, czrk.update_time
-          from czrk
-          left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
-          where czrk.is_del = 'Y' and czrk.update_time &gt;= #{startTime} and czrk.update_time &lt;= #{endTime}
-          <if test="userName != null  and userName != ''">
-              and (czrk.user_name like concat('%', #{userName}, '%') or czrk.id_card like concat('%', #{userName}, '%'))
-          </if>-->
+    <select id="countByHjJs" resultType="int">
+        SELECT COUNT(DISTINCT(jzdz.id_card)) from czrk_jzdz jzdz
+        where jzdz.status = 'N' and jzdz.update_time &gt;= #{startTime} and jzdz.update_time &lt;= #{endTime}
+        <!-- SELECT czrk.id, czrk.update_time
+         from czrk
+         left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
+         where czrk.is_del = 'Y' and czrk.update_time &gt;= #{startTime} and czrk.update_time &lt;= #{endTime}
+         <if test="userName != null  and userName != ''">
+             and (czrk.user_name like concat('%', #{userName}, '%') or czrk.id_card like concat('%', #{userName}, '%'))
+         </if>-->
 
         <choose>
             <when test="type == 1">and jzdz.province_id = #{areaId}</when>
@@ -1036,9 +1049,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     <update id="confirmInfoByIds">
         update czrk
         <trim prefix="SET" suffixOverrides=",">
-        is_confirm = 'Y',
-        <if test="userName != null and userName !=''">  confirm_info_user = #{userName},</if>
-        confirm_info_user_time = sysdate()
+            is_confirm = 'Y',
+            <if test="userName != null and userName !=''">confirm_info_user = #{userName},</if>
+            confirm_info_user_time = sysdate()
         </trim>
         where id in
         <foreach collection="ids" item="id" open="(" separator="," close=")">
@@ -1046,7 +1059,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         </foreach>
     </update>
 
-    <insert id="insertConfirmInfoUser"  useGeneratedKeys="true" keyProperty="id">
+    <insert id="insertConfirmInfoUser" useGeneratedKeys="true" keyProperty="id">
         insert into confim_info_user
         <trim prefix="(" suffix=")" suffixOverrides=",">
             <if test="confirmInfoUser != null">confirm_info_user,</if>
@@ -1063,9 +1076,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </insert>
 
 
-
-    <select id="selectCzrkList"  resultMap="CzrkResult">
-        select c.id,z.id as czrk_jzdz_id,c.user_name,c.id_card,z.province_id, z.province, z.city_id, z.city, z.region_id, z.region, z.town_id as village_towns_id, z.town as village_towns, z.village_id, z.village, z.now_in,c.phone_num,c.house_type,c.rlr,c.rlr_nike,c.confirm_info_user,c.confirm_info_nike_user,c.confirm_info_user_time
+    <select id="selectCzrkList" resultMap="CzrkResult">
+        select c.id,z.id as czrk_jzdz_id,c.user_name,c.id_card,z.province_id, z.province, z.city_id, z.city,
+        z.region_id, z.region, z.town_id as village_towns_id, z.town as village_towns, z.village_id, z.village,
+        z.now_in,c.phone_num,c.house_type,c.rlr,c.rlr_nike,c.confirm_info_user,c.confirm_info_nike_user,c.confirm_info_user_time
         from czrk_jzdz z left join czrk c on c.id = z.czrk_id
         <where>
             <!-- 已认领 -->
@@ -1076,40 +1090,40 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             </if>
             <if test="params.startAge != null  and params.startAge != ''">and c.age &gt;= #{params.startAge}</if>
             <if test="params.endAge != null  and params.endAge != ''">and c.age &lt;= #{params.endAge}</if>
-            <if test="gender != null  and gender != ''"> and c.gender = #{gender}</if>
-            <if test="age != null "> and c.age = #{age}</if>
-            <if test="birthday != null "> and c.birthday = #{birthday}</if>
-            <if test="idCard != null  and idCard != ''"> and c.id_card = #{idCard}</if>
-            <if test="phoneNum != null  and phoneNum != ''"> and c.phone_num = #{phoneNum}</if>
-            <if test="code != null  and code != ''"> and c.code = #{code}</if>
-            <if test="houseType != null  and houseType != ''"> and c.house_type = #{houseType}</if>
-            <if test="rlr != null  and rlr != ''"> and c.rlr = #{rlr}</if>
-            <if test="rlTime != null "> and c.rl_time = #{rlTime}</if>
-            <if test="yhzgx != null  and yhzgx != ''"> and c.yhzgx = #{yhzgx}</if>
-            <if test="workUnit != null  and workUnit != ''"> and c.work_unit = #{workUnit}</if>
-            <if test="provinceId != null  and provinceId != ''"> and c.province_id = #{provinceId}</if>
-            <if test="province != null  and province != ''"> and c.province = #{province}</if>
-            <if test="cityId != null  and cityId != ''"> and c.city_id = #{cityId}</if>
-            <if test="city != null  and city != ''"> and c.city = #{city}</if>
-            <if test="regionId != null  and regionId != ''"> and c.region_id = #{regionId}</if>
-            <if test="region != null  and region != ''"> and c.region = #{region}</if>
-            <if test="villageTownsId != null  and villageTownsId != ''"> and c.village_towns_id = #{villageTownsId}</if>
-            <if test="villageTowns != null  and villageTowns != ''"> and c.village_towns = #{villageTowns}</if>
-            <if test="villageId != null  and villageId != ''"> and c.village_id = #{villageId}</if>
-            <if test="village != null  and village != ''"> and c.village = #{village}</if>
+            <if test="gender != null  and gender != ''">and c.gender = #{gender}</if>
+            <if test="age != null ">and c.age = #{age}</if>
+            <if test="birthday != null ">and c.birthday = #{birthday}</if>
+            <if test="idCard != null  and idCard != ''">and c.id_card = #{idCard}</if>
+            <if test="phoneNum != null  and phoneNum != ''">and c.phone_num = #{phoneNum}</if>
+            <if test="code != null  and code != ''">and c.code = #{code}</if>
+            <if test="houseType != null  and houseType != ''">and c.house_type = #{houseType}</if>
+            <if test="rlr != null  and rlr != ''">and c.rlr = #{rlr}</if>
+            <if test="rlTime != null ">and c.rl_time = #{rlTime}</if>
+            <if test="yhzgx != null  and yhzgx != ''">and c.yhzgx = #{yhzgx}</if>
+            <if test="workUnit != null  and workUnit != ''">and c.work_unit = #{workUnit}</if>
+            <if test="provinceId != null  and provinceId != ''">and c.province_id = #{provinceId}</if>
+            <if test="province != null  and province != ''">and c.province = #{province}</if>
+            <if test="cityId != null  and cityId != ''">and c.city_id = #{cityId}</if>
+            <if test="city != null  and city != ''">and c.city = #{city}</if>
+            <if test="regionId != null  and regionId != ''">and c.region_id = #{regionId}</if>
+            <if test="region != null  and region != ''">and c.region = #{region}</if>
+            <if test="villageTownsId != null  and villageTownsId != ''">and c.village_towns_id = #{villageTownsId}</if>
+            <if test="villageTowns != null  and villageTowns != ''">and c.village_towns = #{villageTowns}</if>
+            <if test="villageId != null  and villageId != ''">and c.village_id = #{villageId}</if>
+            <if test="village != null  and village != ''">and c.village = #{village}</if>
             <!--    <if test="villagerGroupId != null  and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
                 <if test="villagerGroup != null  and villagerGroup != ''"> and villager_group = #{villagerGroup}</if>-->
-            <if test="nowIn != null  and nowIn != ''"> and c.now_in = #{nowIn}</if>
-            <if test="status != null  and status != ''"> and c.status = #{status}</if>
-            <if test="isConfirm != null  and isConfirm != ''"> and c.is_confirm = #{isConfirm}</if>
-            <if test="isDel != null  and isDel != ''"> and c.is_del = #{isDel}</if>
-            <if test="deleteReason != null  and deleteReason != ''"> and c.delete_reason = #{deleteReason}</if>
-            <if test="gridId != null  and gridId != ''"> and c.grid_id = #{gridId}</if>
-            <if test="provinceIdXjd != null "> and z.province_id = #{provinceIdXjd}</if>
-            <if test="cityIdXjd != null "> and z.city_id = #{cityIdXjd}</if>
-            <if test="regionIdXjd != null "> and z.region_id = #{regionIdXjd}</if>
-            <if test="villageTownsIdXjd != null "> and z.town_id = #{villageTownsIdXjd}</if>
-            <if test="villageIdXjd != null "> and z.village_id = #{villageIdXjd}</if>
+            <if test="nowIn != null  and nowIn != ''">and c.now_in = #{nowIn}</if>
+            <if test="status != null  and status != ''">and c.status = #{status}</if>
+            <if test="isConfirm != null  and isConfirm != ''">and c.is_confirm = #{isConfirm}</if>
+            <if test="isDel != null  and isDel != ''">and c.is_del = #{isDel}</if>
+            <if test="deleteReason != null  and deleteReason != ''">and c.delete_reason = #{deleteReason}</if>
+            <if test="gridId != null  and gridId != ''">and c.grid_id = #{gridId}</if>
+            <if test="provinceIdXjd != null ">and z.province_id = #{provinceIdXjd}</if>
+            <if test="cityIdXjd != null ">and z.city_id = #{cityIdXjd}</if>
+            <if test="regionIdXjd != null ">and z.region_id = #{regionIdXjd}</if>
+            <if test="villageTownsIdXjd != null ">and z.town_id = #{villageTownsIdXjd}</if>
+            <if test="villageIdXjd != null ">and z.village_id = #{villageIdXjd}</if>
             <if test="deptIdList != null and deptIdList.size() > 0">
                 and c.dept_id in
                 <foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
@@ -1127,8 +1141,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </select>
 
 
-
-
     <select id="selectCzrkByCode" resultType="java.lang.Integer" resultMap="CzrkResult">
        select id_card from czrk where is_del = 'N' and code = #{code} and house_type = '是' limit 1;
     </select>
@@ -1148,8 +1160,68 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         where is_del = 'N' and id_card = #{idCard} limit 1;
     </select>
 
-    <select id="selectLost"  resultMap="CzrkResult">
+    <select id="selectLost" resultMap="CzrkResult">
         <include refid="selectCzrkVo"/>
         where is_confirm = 'Y' and (village_towns is null or village_towns = '') and is_del ='N'
     </select>
+
+    <select id="unusualList"  resultMap="CzrkResult">
+        select id, user_name, phone_num,dept_id, id_card, gender, province, city, region, village_towns, village,
+        villager_group, grid_id
+        , house_type, update_by, code, rlr,rlr_nike, update_time, delete_reason,
+        now_in,is_confirm,confirm_info_user,confirm_info_nike_user,confirm_info_user_time
+        from czrk
+        <where>
+            status != 1
+            <!-- 已认领 -->
+            <if test="isRl != null and isRl != ''">and is_rl = #{isRl}</if>
+
+            <if test="userName != null  and userName != ''">
+                and user_name like concat(#{userName}, '%')
+            </if>
+            <if test="params.startAge != null  and params.startAge != ''">and age &gt;= #{params.startAge}</if>
+            <if test="params.endAge != null  and params.endAge != ''">and age &lt;= #{params.endAge}</if>
+            <if test="gender != null  and gender != ''">and gender = #{gender}</if>
+            <if test="age != null ">and age = #{age}</if>
+            <if test="birthday != null ">and birthday = #{birthday}</if>
+            <if test="idCard != null  and idCard != ''">and id_card = #{idCard}</if>
+            <if test="phoneNum != null  and phoneNum != ''">and phone_num = #{phoneNum}</if>
+            <if test="code != null  and code != ''">and code = #{code}</if>
+            <if test="houseType != null  and houseType != ''">and house_type = #{houseType}</if>
+            <if test="rlr != null  and rlr != ''">and rlr = #{rlr}</if>
+            <if test="rlTime != null ">and rl_time = #{rlTime}</if>
+            <if test="yhzgx != null  and yhzgx != ''">and yhzgx = #{yhzgx}</if>
+            <if test="workUnit != null  and workUnit != ''">and work_unit = #{workUnit}</if>
+            <if test="provinceId != null  and provinceId != ''">and province_id = #{provinceId}</if>
+            <if test="province != null  and province != ''">and province = #{province}</if>
+            <if test="cityId != null  and cityId != ''">and city_id = #{cityId}</if>
+            <if test="city != null  and city != ''">and city = #{city}</if>
+            <if test="regionId != null  and regionId != ''">and region_id = #{regionId}</if>
+            <if test="region != null  and region != ''">and region = #{region}</if>
+            <if test="villageTownsId != null  and villageTownsId != ''">and village_towns_id = #{villageTownsId}</if>
+            <if test="villageTowns != null  and villageTowns != ''">and village_towns = #{villageTowns}</if>
+            <if test="villageId != null  and villageId != ''">and village_id = #{villageId}</if>
+            <if test="village != null  and village != ''">and village = #{village}</if>
+            <!--    <if test="villagerGroupId != null  and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
+                <if test="villagerGroup != null  and villagerGroup != ''"> and villager_group = #{villagerGroup}</if>-->
+            <if test="nowIn != null  and nowIn != ''">and now_in = #{nowIn}</if>
+            <if test="isConfirm != null  and isConfirm != ''">and is_confirm = #{isConfirm}</if>
+            <if test="isDel != null  and isDel != ''">and is_del = #{isDel}</if>
+            <if test="deleteReason != null  and deleteReason != ''">and delete_reason = #{deleteReason}</if>
+            <if test="gridId != null  and gridId != ''">and grid_id = #{gridId}</if>
+            <if test="deptIdList != null and deptIdList.size() > 0">
+                and dept_id in
+                <foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
+                    #{deptId}
+                </foreach>
+            </if>
+            <if test="idCardList != null and idCardList.size() > 0">
+                and id_card in
+                <foreach item="idCard" collection="idCardList" open="(" separator="," close=")">
+                    #{idCard}
+                </foreach>
+            </if>
+        </where>
+        order by create_time DESC
+    </select>
 </mapper>

Niektoré súbory nie sú zobrazené, pretože je v týchto rozdielových dátach zmenené mnoho súborov