|
@@ -50,6 +50,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<result property="progress" column="progress" />
|
|
<result property="progress" column="progress" />
|
|
<result property="deptId" column="dept_id" />
|
|
<result property="deptId" column="dept_id" />
|
|
<result property="rlr" column="rlr" />
|
|
<result property="rlr" column="rlr" />
|
|
|
|
+ <result property="yhzgx" column="yhzgx" />
|
|
<result property="deleteReason" column="delete_reason" />
|
|
<result property="deleteReason" column="delete_reason" />
|
|
<collection property="vaccineInfoUserList" javaType="java.util.List" resultMap="VaccineInfoUser" />
|
|
<collection property="vaccineInfoUserList" javaType="java.util.List" resultMap="VaccineInfoUser" />
|
|
</resultMap>
|
|
</resultMap>
|
|
@@ -385,14 +386,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
<select id="listByCode" resultMap="VaccineInfoResult">
|
|
<select id="listByCode" resultMap="VaccineInfoResult">
|
|
select vi.id, vi.user_name, vi.phone_num, vi.id_card, vi.gender, vi.province, vi.city, vi.region, vi.now_in
|
|
select vi.id, 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.rlr
|
|
|
|
|
|
+ , vi.house_type, vi.update_by, vi.code, vi.rlr, vi.yhzgx
|
|
from vaccine_info vi
|
|
from vaccine_info vi
|
|
where vi.is_del = 'N' and code = #{code}
|
|
where vi.is_del = 'N' and code = #{code}
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="listByRlry" resultMap="VaccineInfoResult">
|
|
<select id="listByRlry" resultMap="VaccineInfoResult">
|
|
select vi.id, vi.user_name, vi.phone_num, vi.id_card, vi.gender, vi.province, vi.city, vi.region, vi.now_in
|
|
select vi.id, 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.rlr, vi.update_time, vi.delete_reason
|
|
|
|
|
|
+ , vi.house_type, vi.update_by, vi.code, vi.rlr, vi.update_time, vi.delete_reason, vi.domicile, vi.now_in
|
|
from vaccine_info vi
|
|
from vaccine_info vi
|
|
<where>
|
|
<where>
|
|
vi.is_del = #{isDel}
|
|
vi.is_del = #{isDel}
|
|
@@ -512,6 +513,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
select * from vaccine_info limit #{startNum}, #{endNum}
|
|
select * from vaccine_info limit #{startNum}, #{endNum}
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
+ <select id="handleData" resultMap="VaccineInfoResult">
|
|
|
|
+ SELECT (DATE_FORMAT(substring(t.id_card, 7, 8), "%Y-%m-%d")) AS birthday
|
|
|
|
+ , ((YEAR(now())) - (YEAR(substring(t.id_card, 7, 8)))) AS age
|
|
|
|
+ , id AS id
|
|
|
|
+ FROM vaccine_info t where age is null or age = 0 or age = ''
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+ <select id="getHouseType" resultType="com.alibaba.fastjson.JSONObject">
|
|
|
|
+ SELECT zjhm idCard, hh code, yhzgx yhzgx FROM std_ga_hjrkxx
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+ <update id="setHouseType">
|
|
|
|
+ update vaccine_info set code = #{code}, yhzgx = #{yhzgx}, house_type = #{houseType} where id_card = #{idCard}
|
|
|
|
+ </update>
|
|
|
|
|
|
<select id="selectVaccineInfoById" parameterType="Long" resultMap="VaccineInfoResult">
|
|
<select id="selectVaccineInfoById" parameterType="Long" resultMap="VaccineInfoResult">
|
|
<include refid="selectVaccineInfoVo"/>
|
|
<include refid="selectVaccineInfoVo"/>
|
|
@@ -679,6 +694,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
where id = #{id}
|
|
where id = #{id}
|
|
</update>
|
|
</update>
|
|
|
|
|
|
|
|
+ <update id="updateAgeBirthday" >
|
|
|
|
+ update vaccine_info
|
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
|
+ <if test="age != null and age != ''">age = #{age},</if>
|
|
|
|
+ <if test="birthday != null and birthday != ''">birthday = #{birthday},</if>
|
|
|
|
+ </trim>
|
|
|
|
+ where id = #{id}
|
|
|
|
+ </update>
|
|
|
|
+
|
|
<update id="update" >
|
|
<update id="update" >
|
|
update vaccine_info
|
|
update vaccine_info
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<trim prefix="SET" suffixOverrides=",">
|