|
@@ -4,7 +4,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
<mapper namespace="com.boman.web.core.mapper.VaccineInfoMapper">
|
|
<mapper namespace="com.boman.web.core.mapper.VaccineInfoMapper">
|
|
|
|
|
|
- <resultMap type="VaccineInfoOperation" id="VaccineInfoResult">
|
|
|
|
|
|
+ <resultMap type="com.boman.domain.VaccineInfoOperation" id="VaccineInfoResult">
|
|
<result property="id" column="id" />
|
|
<result property="id" column="id" />
|
|
<result property="villageTowns" column="village_towns" />
|
|
<result property="villageTowns" column="village_towns" />
|
|
<result property="village" column="village" />
|
|
<result property="village" column="village" />
|
|
@@ -50,7 +50,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<collection property="vaccineInfoUserList" javaType="java.util.List" resultMap="VaccineInfoUser" />
|
|
<collection property="vaccineInfoUserList" javaType="java.util.List" resultMap="VaccineInfoUser" />
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
- <resultMap id="VaccineInfoUser" type="com.boman.web.core.domain.VaccineInfoUser">
|
|
|
|
|
|
+ <resultMap id="VaccineInfoUser" type="com.boman.domain.VaccineInfoUser">
|
|
<id property="id" column="id_user" />
|
|
<id property="id" column="id_user" />
|
|
<result property="idCard" column="id_card_user" />
|
|
<result property="idCard" column="id_card_user" />
|
|
<result property="vaccineName" column="vaccine_name_user" />
|
|
<result property="vaccineName" column="vaccine_name_user" />
|
|
@@ -75,7 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
on vi.id_card = viu.id_card and viu.is_del = 'N'
|
|
on vi.id_card = viu.id_card and viu.is_del = 'N'
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
- <select id="selectVaccineInfoList" parameterType="VaccineInfoOperation" resultMap="VaccineInfoResult">
|
|
|
|
|
|
+ <select id="selectVaccineInfoList" resultMap="VaccineInfoResult">
|
|
select vi.id, vi.village_towns, vi.village, vi.villager_group,vi.age, vi.house_type, vi.domicile, vi.province, vi.city,vi.should_slow,
|
|
select vi.id, vi.village_towns, vi.village, vi.villager_group,vi.age, vi.house_type, vi.domicile, vi.province, vi.city,vi.should_slow,
|
|
vi.region, vi.user_name, vi.gender, vi.id_card, vi.phone_num, vi.key_industries, vi.is_vaccination, vi.vaccine_name, vi.jici,
|
|
vi.region, vi.user_name, vi.gender, vi.id_card, vi.phone_num, vi.key_industries, vi.is_vaccination, vi.vaccine_name, vi.jici,
|
|
vi.vaccination_time, vi.vaccination_place, vi.contraindication, vi.suspend,vi.suspend_url,vi.other_url,vi.vaccination_time,
|
|
vi.vaccination_time, vi.vaccination_place, vi.contraindication, vi.suspend,vi.suspend_url,vi.other_url,vi.vaccination_time,
|
|
@@ -158,7 +158,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
and vi.is_del = 'N'
|
|
and vi.is_del = 'N'
|
|
</select>
|
|
</select>
|
|
|
|
|
|
- <insert id="insertVaccineInfo" parameterType="VaccineInfoOperation" useGeneratedKeys="true" keyProperty="id">
|
|
|
|
|
|
+ <insert id="insertVaccineInfo" useGeneratedKeys="true" keyProperty="id">
|
|
insert into vaccine_info
|
|
insert into vaccine_info
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="villageTowns != null">village_towns,</if>
|
|
<if test="villageTowns != null">village_towns,</if>
|
|
@@ -250,7 +250,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</trim>
|
|
</trim>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
- <update id="updateVaccineInfo" parameterType="VaccineInfoOperation">
|
|
|
|
|
|
+ <update id="updateVaccineInfo" >
|
|
update vaccine_info
|
|
update vaccine_info
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="villageTowns != null">village_towns = #{villageTowns},</if>
|
|
<if test="villageTowns != null">village_towns = #{villageTowns},</if>
|
|
@@ -299,6 +299,55 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
where id = #{id}
|
|
where id = #{id}
|
|
</update>
|
|
</update>
|
|
|
|
|
|
|
|
+ <update id="update" >
|
|
|
|
+ update vaccine_info
|
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
|
+ <if test="villageTowns != null">village_towns = #{villageTowns},</if>
|
|
|
|
+ <if test="village != null">village = #{village},</if>
|
|
|
|
+ <if test="villagerGroup != null">villager_group = #{villagerGroup},</if>
|
|
|
|
+ <if test="houseType != null">house_type = #{houseType},</if>
|
|
|
|
+ <if test="domicile != null">domicile = #{domicile},</if>
|
|
|
|
+ <if test="province != null">province = #{province},</if>
|
|
|
|
+ <if test="city != null">city = #{city},</if>
|
|
|
|
+ <if test="region != null and region != ''">region = #{region},</if>
|
|
|
|
+ <if test="userName != null">user_name = #{userName},</if>
|
|
|
|
+ <if test="gender != null">gender = #{gender},</if>
|
|
|
|
+<!-- <if test="idCard != null">id_card = #{idCard},</if>-->
|
|
|
|
+ <if test="phoneNum != null">phone_num = #{phoneNum},</if>
|
|
|
|
+ <if test="keyIndustries != null">key_industries = #{keyIndustries},</if>
|
|
|
|
+ <if test="isVaccination != null">is_vaccination = #{isVaccination},</if>
|
|
|
|
+ <if test="vaccineName != null">vaccine_name = #{vaccineName},</if>
|
|
|
|
+ <if test="jici != null">jici = #{jici},</if>
|
|
|
|
+ <if test="vaccinationTime != null">vaccination_time = #{vaccinationTime},</if>
|
|
|
|
+ <if test="vaccinationPlace != null">vaccination_place = #{vaccinationPlace},</if>
|
|
|
|
+ <if test="contraindication != null">contraindication = #{contraindication},</if>
|
|
|
|
+ <if test="suspend != null">suspend = #{suspend},</if>
|
|
|
|
+ <if test="shouldBe != null">should_be = #{shouldBe},</if>
|
|
|
|
+ <if test="other != null">other = #{other},</if>
|
|
|
|
+ <if test="progress != null">progress = #{progress},</if>
|
|
|
|
+ <if test="remark != null">remark = #{remark},</if>
|
|
|
|
+ <if test="status != null">status = #{status},</if>
|
|
|
|
+ <if test="createBy != null">create_by = #{createBy},</if>
|
|
|
|
+ <if test="createTime != null">create_time = #{createTime},</if>
|
|
|
|
+ <if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
|
+ <if test="isDel != null and isDel != ''">is_del = #{isDel},</if>
|
|
|
|
+ <if test="code != null and code != ''">code = #{code},</if>
|
|
|
|
+ <if test="birthday != null and birthday != ''">birthday = #{birthday},</if>
|
|
|
|
+ <if test="workUnit != null and workUnit != ''">work_unit = #{workUnit},</if>
|
|
|
|
+ <if test="crowdClassification != null and crowdClassification != ''">crowd_classification = #{crowdClassification},</if>
|
|
|
|
+ <if test="manufacturer != null and manufacturer != ''">manufacturer = #{manufacturer},</if>
|
|
|
|
+ <if test="nowIn != null and nowIn != ''">now_in = #{nowIn},</if>
|
|
|
|
+ <if test="url != null and url != ''">url = #{url},</if>
|
|
|
|
+ <if test="shouldSlow != null and shouldSlow != ''">should_slow = #{shouldSlow},</if>
|
|
|
|
+ <if test="suspendUrl != null and suspendUrl != ''">suspend_url = #{suspendUrl},</if>
|
|
|
|
+ <if test="otherUrl != null and otherUrl != ''">other_url = #{otherUrl},</if>
|
|
|
|
+ <if test="age != null and age != ''">age = #{age},</if>
|
|
|
|
+ <if test="deptId != null">dept_id = #{deptId},</if>
|
|
|
|
+ </trim>
|
|
|
|
+ where code = #{code} or (id_card like concat('%', #{idCard}, '%') and user_name like concat('%', #{userName}, '%'))
|
|
|
|
+ </update>
|
|
|
|
+
|
|
<delete id="deleteVaccineInfoById" parameterType="Long">
|
|
<delete id="deleteVaccineInfoById" parameterType="Long">
|
|
update vaccine_info set is_del = 'Y' where id = #{id}
|
|
update vaccine_info set is_del = 'Y' where id = #{id}
|
|
</delete>
|
|
</delete>
|
|
@@ -311,7 +360,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</delete>
|
|
</delete>
|
|
|
|
|
|
|
|
|
|
- <select id="findHjInfo" parameterType="VaccineInfoOperation" resultMap="VaccineInfoResult">
|
|
|
|
|
|
+ <select id="findHjInfo" resultMap="VaccineInfoResult">
|
|
select id, user_name ,gender, birthday,age,code from vaccine_info
|
|
select id, user_name ,gender, birthday,age,code from vaccine_info
|
|
<where>
|
|
<where>
|
|
is_del = 'N'
|
|
is_del = 'N'
|