|
@@ -1,98 +1,98 @@
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<!DOCTYPE mapper
|
|
<!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">
|
|
<mapper namespace="com.boman.web.core.mapper.CzrkMapper">
|
|
-
|
|
|
|
|
|
+
|
|
<resultMap type="com.boman.domain.Czrk" id="CzrkResult">
|
|
<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>
|
|
|
|
|
|
<resultMap type="com.boman.domain.CzrkJzdz" id="CzrkJzdzResult">
|
|
<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>
|
|
|
|
|
|
|
|
|
|
<resultMap type="com.boman.domain.SysDept" id="SysDeptResult">
|
|
<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>
|
|
|
|
|
|
<resultMap type="com.boman.web.core.domain.ConfirmInfoUser" id="ConfrimInforUserResult">
|
|
<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>
|
|
</resultMap>
|
|
<sql id="selectCzrkVo">
|
|
<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
|
|
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
|
|
, update_by, update_time, is_del, delete_reason, is_rl, key_industries from czrk
|
|
</sql>
|
|
</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
|
|
from czrk
|
|
<where>
|
|
<where>
|
|
<!-- 已认领 -->
|
|
<!-- 已认领 -->
|
|
@@ -114,35 +116,35 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</if>
|
|
</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and age >= #{params.startAge}</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and age <= #{params.endAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and age <= #{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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and dept_id in
|
|
and dept_id in
|
|
<foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
|
|
<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
|
|
order by create_time DESC
|
|
</select>
|
|
</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
|
|
from czrk c left join czrk_jzdz z on c.id =z.czrk_id
|
|
<where>
|
|
<where>
|
|
<!-- 已认领 -->
|
|
<!-- 已认领 -->
|
|
@@ -172,34 +176,34 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</if>
|
|
</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and c.age >= #{params.startAge}</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and c.age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and c.age <= #{params.endAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and c.age <= #{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="villagerGroupId != null and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
|
|
<if test="villagerGroup != null and villagerGroup != ''"> and villager_group = #{villagerGroup}</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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and c.dept_id in
|
|
and c.dept_id in
|
|
<foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
|
|
<foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
|
|
@@ -212,40 +216,40 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
#{idCard}
|
|
#{idCard}
|
|
</foreach>
|
|
</foreach>
|
|
</if>
|
|
</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>
|
|
</where>
|
|
order by c.create_time DESC
|
|
order by c.create_time DESC
|
|
</select>
|
|
</select>
|
|
|
|
|
|
- <select id="listByRlryRel" resultType="com.boman.domain.Czrk">
|
|
|
|
|
|
+ <select id="listByRlryRel" resultType="com.boman.domain.Czrk">
|
|
SELECT
|
|
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
|
|
from czrk
|
|
left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
|
|
left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
|
|
<where>
|
|
<where>
|
|
@@ -258,41 +262,45 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</if>
|
|
</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and czrk.age >= #{params.startAge}</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and czrk.age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and czrk.age <= #{params.endAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and czrk.age <= #{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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and czrk.dept_id in
|
|
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
|
|
GROUP BY czrk.id ORDER BY czrk.update_time DESC
|
|
</select>
|
|
</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
|
|
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
|
|
, vi.gender, vi.province, vi.city, vi.region, vi.now_in, vi.house_type, vi.update_by, vi.code
|
|
from czrk vi
|
|
from czrk vi
|
|
@@ -315,23 +323,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="villageTowns != null and villageTowns != ''">
|
|
<if test="villageTowns != null and villageTowns != ''">
|
|
and vi.village_towns = #{villageTowns}
|
|
and vi.village_towns = #{villageTowns}
|
|
</if>
|
|
</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 >= #{params.startAge}</if>
|
|
<!--<if test="params.startAge != null and params.startAge != ''"> and vi.age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''"> and vi.age <= #{params.endAge}</if>-->
|
|
<if test="params.endAge != null and params.endAge != ''"> and vi.age <= #{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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and vi.dept_id in
|
|
and vi.dept_id in
|
|
@@ -378,24 +386,24 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="villageTowns != null and villageTowns != ''">
|
|
<if test="villageTowns != null and villageTowns != ''">
|
|
and vi.village_towns = #{villageTowns}
|
|
and vi.village_towns = #{villageTowns}
|
|
</if>
|
|
</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 >= #{params.startAge}</if>
|
|
<!--<if test="params.startAge != null and params.startAge != ''"> and vi.age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''"> and vi.age <= #{params.endAge}</if>-->
|
|
<if test="params.endAge != null and params.endAge != ''"> and vi.age <= #{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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and vi.dept_id in
|
|
and vi.dept_id in
|
|
@@ -432,7 +440,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="listByCode" resultMap="CzrkResult">
|
|
<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
|
|
, vi.house_type, vi.update_by, vi.code, vi.rlr, vi.yhzgx
|
|
from czrk vi
|
|
from czrk vi
|
|
<!--把户主放第一位-->
|
|
<!--把户主放第一位-->
|
|
@@ -450,7 +459,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
-
|
|
|
|
<select id="countCzrk" resultType="int">
|
|
<select id="countCzrk" resultType="int">
|
|
select count(vi.id)
|
|
select count(vi.id)
|
|
from czrk vi
|
|
from czrk vi
|
|
@@ -499,7 +507,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="listByCzXz1" resultType="com.boman.domain.Czrk">
|
|
<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
|
|
ANY_VALUE(jzdz.create_time) createTime from czrk_jzdz jzdz
|
|
where jzdz.status = 'Y' and jzdz.create_time >= #{startTime} and jzdz.create_time <= #{endTime}
|
|
where jzdz.status = 'Y' and jzdz.create_time >= #{startTime} and jzdz.create_time <= #{endTime}
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
<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">
|
|
<select id="selectCzrkById" parameterType="Long" resultMap="CzrkResult">
|
|
<include refid="selectCzrkVo"/>
|
|
<include refid="selectCzrkVo"/>
|
|
- where id = #{id} and is_del = 'N' limit 1
|
|
|
|
|
|
+ where id = #{id} and is_del = 'N' limit 1
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
@@ -610,7 +618,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<!-- 已认领 -->
|
|
<!-- 已认领 -->
|
|
and vi.is_rl = '是'
|
|
and vi.is_rl = '是'
|
|
<if test="idCard != null and idCard != ''">
|
|
<if test="idCard != null and idCard != ''">
|
|
- and vi.id_card = #{idCard}
|
|
|
|
|
|
+ and vi.id_card = #{idCard}
|
|
</if>
|
|
</if>
|
|
<if test="houseType != null and houseType != ''">
|
|
<if test="houseType != null and houseType != ''">
|
|
and vi.house_type = #{houseType}
|
|
and vi.house_type = #{houseType}
|
|
@@ -619,7 +627,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
and vi.is_confirm = #{isConfirm}
|
|
and vi.is_confirm = #{isConfirm}
|
|
</if>
|
|
</if>
|
|
<if test="userName != null and userName != ''">
|
|
<if test="userName != null and userName != ''">
|
|
- and vi.user_name like concat(#{userName}, '%')
|
|
|
|
|
|
+ and vi.user_name like concat(#{userName}, '%')
|
|
</if>
|
|
</if>
|
|
<choose>
|
|
<choose>
|
|
<when test="type == 1">and vi.province_id = #{areaId}</when>
|
|
<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}
|
|
and vi.is_confirm = #{isConfirm}
|
|
</if>
|
|
</if>
|
|
<if test="userName != null and userName != ''">
|
|
<if test="userName != null and userName != ''">
|
|
- and vi.user_name like concat(#{userName}, '%')
|
|
|
|
|
|
+ and vi.user_name like concat(#{userName}, '%')
|
|
</if>
|
|
</if>
|
|
<choose>
|
|
<choose>
|
|
<when test="type == 1">and vi.province_id = #{areaId}</when>
|
|
<when test="type == 1">and vi.province_id = #{areaId}</when>
|
|
@@ -686,7 +694,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
- <insert id="insertCzrk" useGeneratedKeys="true" keyProperty="id">
|
|
|
|
|
|
+ <insert id="insertCzrk" useGeneratedKeys="true" keyProperty="id">
|
|
insert into czrk
|
|
insert into czrk
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="userName != null">user_name,</if>
|
|
<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="isDel != null and isDel != ''">is_del,</if>
|
|
<if test="deleteReason != null">delete_reason,</if>
|
|
<if test="deleteReason != null">delete_reason,</if>
|
|
create_time, update_time
|
|
create_time, update_time
|
|
- </trim>
|
|
|
|
|
|
+ </trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="userName != null">#{userName},</if>
|
|
<if test="userName != null">#{userName},</if>
|
|
<if test="gender != null">#{gender},</if>
|
|
<if test="gender != null">#{gender},</if>
|
|
@@ -772,7 +780,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</trim>
|
|
</trim>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
- <update id="updateCzrk" >
|
|
|
|
|
|
+ <update id="updateCzrk">
|
|
update czrk
|
|
update czrk
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="userName != null">user_name = #{userName},</if>
|
|
<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="status != null">status = #{status},</if>
|
|
<if test="isConfirm != null and isConfirm != ''">is_confirm = #{isConfirm},</if>
|
|
<if test="isConfirm != null and isConfirm != ''">is_confirm = #{isConfirm},</if>
|
|
<if test="confirmInfoUser != null and confirmInfoUser != ''">confirm_info_user = #{confirmInfoUser},</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="confirmInfoUserTime != null ">confirm_info_user_time = #{confirmInfoUserTime},</if>
|
|
<if test="createBy != null">create_by = #{createBy},</if>
|
|
<if test="createBy != null">create_by = #{createBy},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
@@ -833,12 +843,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
where id = #{id}
|
|
where id = #{id}
|
|
</update>
|
|
</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 id="deleteCzrk">
|
|
update czrk
|
|
update czrk
|
|
@@ -867,28 +877,31 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
where is_del = 'N' and code = #{czrk.code};
|
|
where is_del = 'N' and code = #{czrk.code};
|
|
</update>
|
|
</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,
|
|
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>
|
|
<where>
|
|
c.is_del = 'N'
|
|
c.is_del = 'N'
|
|
and cj.status = 'Y'
|
|
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>
|
|
</where>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="stsByAppletCz" resultMap="CzrkResult">
|
|
<select id="stsByAppletCz" resultMap="CzrkResult">
|
|
SELECT
|
|
SELECT
|
|
- czrk.id,
|
|
|
|
- czrk.is_rl
|
|
|
|
|
|
+ czrk.id,
|
|
|
|
+ czrk.is_rl
|
|
from czrk
|
|
from czrk
|
|
left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
|
|
left join czrk_jzdz jzdz on czrk.id = jzdz.czrk_id
|
|
<where>
|
|
<where>
|
|
czrk.is_del = 'N' and jzdz.status = 'Y'
|
|
czrk.is_del = 'N' and jzdz.status = 'Y'
|
|
<if test="idCard != null and idCard != ''">
|
|
<if test="idCard != null and idCard != ''">
|
|
- and czrk.id_card = #{idCard}
|
|
|
|
|
|
+ and czrk.id_card = #{idCard}
|
|
</if>
|
|
</if>
|
|
<if test="houseType != null and houseType != ''">
|
|
<if test="houseType != null and houseType != ''">
|
|
and czrk.house_type = #{houseType}
|
|
and czrk.house_type = #{houseType}
|
|
@@ -897,7 +910,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
and czrk.is_confirm = #{isConfirm}
|
|
and czrk.is_confirm = #{isConfirm}
|
|
</if>
|
|
</if>
|
|
<if test="userName != null and userName != ''">
|
|
<if test="userName != null and userName != ''">
|
|
- and czrk.user_name like concat(#{userName}, '%')
|
|
|
|
|
|
+ and czrk.user_name like concat(#{userName}, '%')
|
|
</if>
|
|
</if>
|
|
<choose>
|
|
<choose>
|
|
<when test="type == 1">and jzdz.province_id = #{areaId}</when>
|
|
<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>
|
|
<when test="type == 5">and jzdz.village_id = #{areaId}</when>
|
|
</choose>
|
|
</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>
|
|
</where>
|
|
GROUP BY czrk.id
|
|
GROUP BY czrk.id
|
|
</select>
|
|
</select>
|
|
@@ -961,16 +974,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
GROUP BY czrk.id
|
|
GROUP BY czrk.id
|
|
</select>
|
|
</select>
|
|
|
|
|
|
- <select id="countByHjJs" resultType="int">
|
|
|
|
- SELECT COUNT(DISTINCT(jzdz.id_card)) from czrk_jzdz jzdz
|
|
|
|
- where jzdz.status = 'N' and jzdz.update_time >= #{startTime} and jzdz.update_time <= #{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 >= #{startTime} and czrk.update_time <= #{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 >= #{startTime} and jzdz.update_time <= #{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 >= #{startTime} and czrk.update_time <= #{endTime}
|
|
|
|
+ <if test="userName != null and userName != ''">
|
|
|
|
+ and (czrk.user_name like concat('%', #{userName}, '%') or czrk.id_card like concat('%', #{userName}, '%'))
|
|
|
|
+ </if>-->
|
|
|
|
|
|
<choose>
|
|
<choose>
|
|
<when test="type == 1">and jzdz.province_id = #{areaId}</when>
|
|
<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 id="confirmInfoByIds">
|
|
update czrk
|
|
update czrk
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<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>
|
|
</trim>
|
|
where id in
|
|
where id in
|
|
<foreach collection="ids" item="id" open="(" separator="," close=")">
|
|
<foreach collection="ids" item="id" open="(" separator="," close=")">
|
|
@@ -1046,7 +1059,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</foreach>
|
|
</foreach>
|
|
</update>
|
|
</update>
|
|
|
|
|
|
- <insert id="insertConfirmInfoUser" useGeneratedKeys="true" keyProperty="id">
|
|
|
|
|
|
+ <insert id="insertConfirmInfoUser" useGeneratedKeys="true" keyProperty="id">
|
|
insert into confim_info_user
|
|
insert into confim_info_user
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="confirmInfoUser != null">confirm_info_user,</if>
|
|
<if test="confirmInfoUser != null">confirm_info_user,</if>
|
|
@@ -1063,9 +1076,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</insert>
|
|
</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
|
|
from czrk_jzdz z left join czrk c on c.id = z.czrk_id
|
|
<where>
|
|
<where>
|
|
<!-- 已认领 -->
|
|
<!-- 已认领 -->
|
|
@@ -1076,40 +1090,40 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</if>
|
|
</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and c.age >= #{params.startAge}</if>
|
|
<if test="params.startAge != null and params.startAge != ''">and c.age >= #{params.startAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and c.age <= #{params.endAge}</if>
|
|
<if test="params.endAge != null and params.endAge != ''">and c.age <= #{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="villagerGroupId != null and villagerGroupId != ''"> and villager_group_id = #{villagerGroupId}</if>
|
|
<if test="villagerGroup != null and villagerGroup != ''"> and villager_group = #{villagerGroup}</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">
|
|
<if test="deptIdList != null and deptIdList.size() > 0">
|
|
and c.dept_id in
|
|
and c.dept_id in
|
|
<foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
|
|
<foreach item="deptId" collection="deptIdList" open="(" separator="," close=")">
|
|
@@ -1127,8 +1141,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
-
|
|
|
|
-
|
|
|
|
<select id="selectCzrkByCode" resultType="java.lang.Integer" resultMap="CzrkResult">
|
|
<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 id_card from czrk where is_del = 'N' and code = #{code} and house_type = '是' limit 1;
|
|
</select>
|
|
</select>
|
|
@@ -1148,8 +1160,68 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
where is_del = 'N' and id_card = #{idCard} limit 1;
|
|
where is_del = 'N' and id_card = #{idCard} limit 1;
|
|
</select>
|
|
</select>
|
|
|
|
|
|
- <select id="selectLost" resultMap="CzrkResult">
|
|
|
|
|
|
+ <select id="selectLost" resultMap="CzrkResult">
|
|
<include refid="selectCzrkVo"/>
|
|
<include refid="selectCzrkVo"/>
|
|
where is_confirm = 'Y' and (village_towns is null or village_towns = '') and is_del ='N'
|
|
where is_confirm = 'Y' and (village_towns is null or village_towns = '') and is_del ='N'
|
|
</select>
|
|
</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 >= #{params.startAge}</if>
|
|
|
|
+ <if test="params.endAge != null and params.endAge != ''">and age <= #{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>
|
|
</mapper>
|