<?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">
<mapper namespace="com.ruoyi.system.mapper.visit.dr.VisitDrTaskSignMapper">
  <resultMap id="BaseResultMap" type="com.ruoyi.system.domain.visit.dr.VisitDrTaskSign">
    <id column="id" jdbcType="VARCHAR" property="id" />
    <result column="task_id" jdbcType="VARCHAR" property="taskId" />
    <result column="checked_object" jdbcType="VARCHAR" property="checkedObject" />
    <result column="telephone" jdbcType="VARCHAR" property="telephone" />
    <result column="address" jdbcType="VARCHAR" property="address" />
    <result column="check_time" jdbcType="VARCHAR" property="checkTime" />
    <result column="check_people" jdbcType="VARCHAR" property="checkPeople" />
    <result column="extfiled_one" jdbcType="VARCHAR" property="extfiledOne" />
    <result column="extfiled_two" jdbcType="VARCHAR" property="extfiledTwo" />
    <result column="extfiled_three" jdbcType="VARCHAR" property="extfiledThree" />
    <result column="extfiled_four" jdbcType="VARCHAR" property="extfiledFour" />
    <result column="extfiled_five" jdbcType="VARCHAR" property="extfiledFive" />
    <result column="extfiled_six" jdbcType="VARCHAR" property="extfiledSix" />
  </resultMap>
  <sql id="Example_Where_Clause">
    <where>
      <foreach collection="oredCriteria" item="criteria" separator="or">
        <if test="criteria.valid">
          <trim prefix="(" prefixOverrides="and" suffix=")">
            <foreach collection="criteria.criteria" item="criterion">
              <choose>
                <when test="criterion.noValue">
                  and ${criterion.condition}
                </when>
                <when test="criterion.singleValue">
                  and ${criterion.condition} #{criterion.value}
                </when>
                <when test="criterion.betweenValue">
                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
                </when>
                <when test="criterion.listValue">
                  and ${criterion.condition}
                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
                    #{listItem}
                  </foreach>
                </when>
              </choose>
            </foreach>
          </trim>
        </if>
      </foreach>
    </where>
  </sql>
  <sql id="Update_By_Example_Where_Clause">
    <where>
      <foreach collection="example.oredCriteria" item="criteria" separator="or">
        <if test="criteria.valid">
          <trim prefix="(" prefixOverrides="and" suffix=")">
            <foreach collection="criteria.criteria" item="criterion">
              <choose>
                <when test="criterion.noValue">
                  and ${criterion.condition}
                </when>
                <when test="criterion.singleValue">
                  and ${criterion.condition} #{criterion.value}
                </when>
                <when test="criterion.betweenValue">
                  and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
                </when>
                <when test="criterion.listValue">
                  and ${criterion.condition}
                  <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
                    #{listItem}
                  </foreach>
                </when>
              </choose>
            </foreach>
          </trim>
        </if>
      </foreach>
    </where>
  </sql>
  <sql id="Base_Column_List">
    id, task_id, checked_object, telephone, address, check_time, check_people, extfiled_one, 
    extfiled_two, extfiled_three, extfiled_four, extfiled_five, extfiled_six
  </sql>
  <select id="selectByExample" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSignExample" resultMap="BaseResultMap">
    select
    <if test="distinct">
      distinct
    </if>
    <include refid="Base_Column_List" />
    from visit_dr_task_sign
    <if test="_parameter != null">
      <include refid="Example_Where_Clause" />
    </if>
    <if test="orderByClause != null">
      order by ${orderByClause}
    </if>
  </select>
  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
    select 
    <include refid="Base_Column_List" />
    from visit_dr_task_sign
    where id = #{id,jdbcType=VARCHAR}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
    delete from visit_dr_task_sign
    where id = #{id,jdbcType=VARCHAR}
  </delete>
  <delete id="deleteByExample" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSignExample">
    delete from visit_dr_task_sign
    <if test="_parameter != null">
      <include refid="Example_Where_Clause" />
    </if>
  </delete>
  <insert id="insert" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSign">
    insert into visit_dr_task_sign (id, task_id, checked_object,
      telephone, address, check_time, 
      check_people, extfiled_one, extfiled_two, 
      extfiled_three, extfiled_four, extfiled_five, 
      extfiled_six)
    values (#{id,jdbcType=VARCHAR}, #{taskId,jdbcType=VARCHAR}, #{checkedObject,jdbcType=VARCHAR}, 
      #{telephone,jdbcType=VARCHAR}, #{address,jdbcType=VARCHAR}, #{checkTime,jdbcType=VARCHAR}, 
      #{checkPeople,jdbcType=VARCHAR}, #{extfiledOne,jdbcType=VARCHAR}, #{extfiledTwo,jdbcType=VARCHAR}, 
      #{extfiledThree,jdbcType=VARCHAR}, #{extfiledFour,jdbcType=VARCHAR}, #{extfiledFive,jdbcType=VARCHAR}, 
      #{extfiledSix,jdbcType=VARCHAR})
  </insert>
  <insert id="insertSelective" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSign">
    insert into visit_dr_task_sign
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">
        id,
      </if>
      <if test="taskId != null">
        task_id,
      </if>
      <if test="checkedObject != null">
        checked_object,
      </if>
      <if test="telephone != null">
        telephone,
      </if>
      <if test="address != null">
        address,
      </if>
      <if test="checkTime != null">
        check_time,
      </if>
      <if test="checkPeople != null">
        check_people,
      </if>
      <if test="extfiledOne != null">
        extfiled_one,
      </if>
      <if test="extfiledTwo != null">
        extfiled_two,
      </if>
      <if test="extfiledThree != null">
        extfiled_three,
      </if>
      <if test="extfiledFour != null">
        extfiled_four,
      </if>
      <if test="extfiledFive != null">
        extfiled_five,
      </if>
      <if test="extfiledSix != null">
        extfiled_six,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="id != null">
        #{id,jdbcType=VARCHAR},
      </if>
      <if test="taskId != null">
        #{taskId,jdbcType=VARCHAR},
      </if>
      <if test="checkedObject != null">
        #{checkedObject,jdbcType=VARCHAR},
      </if>
      <if test="telephone != null">
        #{telephone,jdbcType=VARCHAR},
      </if>
      <if test="address != null">
        #{address,jdbcType=VARCHAR},
      </if>
      <if test="checkTime != null">
        #{checkTime,jdbcType=VARCHAR},
      </if>
      <if test="checkPeople != null">
        #{checkPeople,jdbcType=VARCHAR},
      </if>
      <if test="extfiledOne != null">
        #{extfiledOne,jdbcType=VARCHAR},
      </if>
      <if test="extfiledTwo != null">
        #{extfiledTwo,jdbcType=VARCHAR},
      </if>
      <if test="extfiledThree != null">
        #{extfiledThree,jdbcType=VARCHAR},
      </if>
      <if test="extfiledFour != null">
        #{extfiledFour,jdbcType=VARCHAR},
      </if>
      <if test="extfiledFive != null">
        #{extfiledFive,jdbcType=VARCHAR},
      </if>
      <if test="extfiledSix != null">
        #{extfiledSix,jdbcType=VARCHAR},
      </if>
    </trim>
  </insert>
  <select id="countByExample" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSignExample" resultType="java.lang.Long">
    select count(*) from visit_dr_task_sign
    <if test="_parameter != null">
      <include refid="Example_Where_Clause" />
    </if>
  </select>
  <update id="updateByExampleSelective" parameterType="map">
    update visit_dr_task_sign
    <set>
      <if test="record.id != null">
        id = #{record.id,jdbcType=VARCHAR},
      </if>
      <if test="record.taskId != null">
        task_id = #{record.taskId,jdbcType=VARCHAR},
      </if>
      <if test="record.checkedObject != null">
        checked_object = #{record.checkedObject,jdbcType=VARCHAR},
      </if>
      <if test="record.telephone != null">
        telephone = #{record.telephone,jdbcType=VARCHAR},
      </if>
      <if test="record.address != null">
        address = #{record.address,jdbcType=VARCHAR},
      </if>
      <if test="record.checkTime != null">
        check_time = #{record.checkTime,jdbcType=VARCHAR},
      </if>
      <if test="record.checkPeople != null">
        check_people = #{record.checkPeople,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledOne != null">
        extfiled_one = #{record.extfiledOne,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledTwo != null">
        extfiled_two = #{record.extfiledTwo,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledThree != null">
        extfiled_three = #{record.extfiledThree,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledFour != null">
        extfiled_four = #{record.extfiledFour,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledFive != null">
        extfiled_five = #{record.extfiledFive,jdbcType=VARCHAR},
      </if>
      <if test="record.extfiledSix != null">
        extfiled_six = #{record.extfiledSix,jdbcType=VARCHAR},
      </if>
    </set>
    <if test="_parameter != null">
      <include refid="Update_By_Example_Where_Clause" />
    </if>
  </update>
  <update id="updateByExample" parameterType="map">
    update visit_dr_task_sign
    set id = #{record.id,jdbcType=VARCHAR},
      task_id = #{record.taskId,jdbcType=VARCHAR},
      checked_object = #{record.checkedObject,jdbcType=VARCHAR},
      telephone = #{record.telephone,jdbcType=VARCHAR},
      address = #{record.address,jdbcType=VARCHAR},
      check_time = #{record.checkTime,jdbcType=VARCHAR},
      check_people = #{record.checkPeople,jdbcType=VARCHAR},
      extfiled_one = #{record.extfiledOne,jdbcType=VARCHAR},
      extfiled_two = #{record.extfiledTwo,jdbcType=VARCHAR},
      extfiled_three = #{record.extfiledThree,jdbcType=VARCHAR},
      extfiled_four = #{record.extfiledFour,jdbcType=VARCHAR},
      extfiled_five = #{record.extfiledFive,jdbcType=VARCHAR},
      extfiled_six = #{record.extfiledSix,jdbcType=VARCHAR}
    <if test="_parameter != null">
      <include refid="Update_By_Example_Where_Clause" />
    </if>
  </update>
  <update id="updateByPrimaryKeySelective" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSign">
    update visit_dr_task_sign
    <set>
      <if test="taskId != null">
        task_id = #{taskId,jdbcType=VARCHAR},
      </if>
      <if test="checkedObject != null">
        checked_object = #{checkedObject,jdbcType=VARCHAR},
      </if>
      <if test="telephone != null">
        telephone = #{telephone,jdbcType=VARCHAR},
      </if>
      <if test="address != null">
        address = #{address,jdbcType=VARCHAR},
      </if>
      <if test="checkTime != null">
        check_time = #{checkTime,jdbcType=VARCHAR},
      </if>
      <if test="checkPeople != null">
        check_people = #{checkPeople,jdbcType=VARCHAR},
      </if>
      <if test="extfiledOne != null">
        extfiled_one = #{extfiledOne,jdbcType=VARCHAR},
      </if>
      <if test="extfiledTwo != null">
        extfiled_two = #{extfiledTwo,jdbcType=VARCHAR},
      </if>
      <if test="extfiledThree != null">
        extfiled_three = #{extfiledThree,jdbcType=VARCHAR},
      </if>
      <if test="extfiledFour != null">
        extfiled_four = #{extfiledFour,jdbcType=VARCHAR},
      </if>
      <if test="extfiledFive != null">
        extfiled_five = #{extfiledFive,jdbcType=VARCHAR},
      </if>
      <if test="extfiledSix != null">
        extfiled_six = #{extfiledSix,jdbcType=VARCHAR},
      </if>
    </set>
    where id = #{id,jdbcType=VARCHAR}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.ruoyi.system.domain.visit.dr.VisitDrTaskSign">
    update visit_dr_task_sign
    set task_id = #{taskId,jdbcType=VARCHAR},
      checked_object = #{checkedObject,jdbcType=VARCHAR},
      telephone = #{telephone,jdbcType=VARCHAR},
      address = #{address,jdbcType=VARCHAR},
      check_time = #{checkTime,jdbcType=VARCHAR},
      check_people = #{checkPeople,jdbcType=VARCHAR},
      extfiled_one = #{extfiledOne,jdbcType=VARCHAR},
      extfiled_two = #{extfiledTwo,jdbcType=VARCHAR},
      extfiled_three = #{extfiledThree,jdbcType=VARCHAR},
      extfiled_four = #{extfiledFour,jdbcType=VARCHAR},
      extfiled_five = #{extfiledFive,jdbcType=VARCHAR},
      extfiled_six = #{extfiledSix,jdbcType=VARCHAR}
    where id = #{id,jdbcType=VARCHAR}
  </update>
</mapper>