<?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.chinaitop.depot.intelligent.fumigation.mapper.TFumigationProcessMapper" >
  <resultMap id="BaseResultMap" type="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcess" >
    <id column="id" property="id" jdbcType="VARCHAR" />
    <result column="fumigation_id" property="fumigationId" jdbcType="VARCHAR" />
    <result column="first_use_drug_time" property="firstUseDrugTime" jdbcType="TIMESTAMP" />
    <result column="first_use_drug_unit" property="firstUseDrugUnit" jdbcType="VARCHAR" />
    <result column="first_use_drug_count" property="firstUseDrugCount" jdbcType="VARCHAR" />
    <result column="circulation_use_time" property="circulationUseTime" jdbcType="VARCHAR" />
    <result column="first_supplement_drug_time" property="firstSupplementDrugTime" jdbcType="TIMESTAMP" />
    <result column="first_supplement_drug_count" property="firstSupplementDrugCount" jdbcType="VARCHAR" />
    <result column="last_supplement_drug_time" property="lastSupplementDrugTime" jdbcType="TIMESTAMP" />
    <result column="last_supplement_drug_count" property="lastSupplementDrugCount" jdbcType="VARCHAR" />
    <result column="total_supplement_drug_times" property="totalSupplementDrugTimes" jdbcType="INTEGER" />
    <result column="total_supplement_drug_count" property="totalSupplementDrugCount" jdbcType="VARCHAR" />
    <result column="total_use_drug_count" property="totalUseDrugCount" jdbcType="VARCHAR" />
    <result column="supplement_drug_type" property="supplementDrugType" jdbcType="VARCHAR" />
    <result column="is_circulation_fine" property="isCirculationFine" jdbcType="INTEGER" />
    <result column="is_use_drug_equipment_fine" property="isUseDrugEquipmentFine" jdbcType="INTEGER" />
    <result column="is_house_tightness_fine" property="isHouseTightnessFine" jdbcType="INTEGER" />
    <result column="is_aerial_work_platform_fine" property="isAerialWorkPlatformFine" jdbcType="INTEGER" />
    <result column="is_phosphine_detector_fine" property="isPhosphineDetectorFine" jdbcType="INTEGER" />
    <result column="is_phosphine_alarm_fine" property="isPhosphineAlarmFine" jdbcType="INTEGER" />
    <result column="is_oxygen_detector_fine" property="isOxygenDetectorFine" jdbcType="INTEGER" />
    <result column="is_air_respirator_fine" property="isAirRespiratorFine" jdbcType="INTEGER" />
    <result column="is_have_warning_sign_fine" property="isHaveWarningSignFine" jdbcType="INTEGER" />
    <result column="is_fire_extinguisher_fine" property="isFireExtinguisherFine" jdbcType="INTEGER" />
    <result column="is_have_first_aid_kit" property="isHaveFirstAidKit" jdbcType="INTEGER" />
    <result column="bulk_start_time" property="bulkStartTime" jdbcType="TIMESTAMP" />
    <result column="bulk_end_time" property="bulkEndTime" jdbcType="TIMESTAMP" />
    <result column="bulk_gas_type" property="bulkGasType" jdbcType="VARCHAR" />
    <result column="bulk_end_toxic_gas_concentration" property="bulkEndToxicGasConcentration" jdbcType="VARCHAR" />
    <result column="drug_residue_rate" property="drugResidueRate" jdbcType="VARCHAR" />
    <result column="dcsqtinfo_id" property="dcsqtinfoId" jdbcType="VARCHAR" />
    <result column="task_state" property="taskState" jdbcType="INTEGER" />
    <result column="task_end_time" property="taskEndTime" jdbcType="TIMESTAMP" />
    <result column="creater" property="creater" jdbcType="INTEGER" />
    <result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
    <result column="update_time" property="updateTime" jdbcType="TIMESTAMP" />
    <result column="org_id" property="orgId" jdbcType="INTEGER" />
    <result column="yqbjyaqjc" property="yqbjyaqjc" jdbcType="VARCHAR" />
    <result column="byqcnlhqnd" property="byqcnlhqnd" jdbcType="DECIMAL" />
    <result column="mbnd" property="mbnd" jdbcType="DECIMAL" />
    <result column="jsbyl" property="jsbyl" jdbcType="DECIMAL" />
    <result column="byzypzr" property="byzypzr" jdbcType="VARCHAR" />
    <result column="fznd" property="fznd" jdbcType="DECIMAL" />
    <result column="mbndwcts" property="mbndwcts" jdbcType="INTEGER" />
    <result column="lswzjc" property="lswzjc" jdbcType="VARCHAR" />
    <result column="lqbwcqdbjcs" property="lqbwcqdbjcs" jdbcType="VARCHAR" />
    <result column="mbsj" property="mbsj" jdbcType="INTEGER" />
    <result column="ctz" property="ctz" jdbcType="DECIMAL" />
    <result column="sqqlhqnd" property="sqqlhqnd" jdbcType="DECIMAL" />
    <result column="sqpzr" property="sqpzr" jdbcType="VARCHAR" />
    <result column="sqcsts" property="sqcsts" jdbcType="INTEGER" />
    <result column="sqjsslhqnd" property="sqjsslhqnd" jdbcType="DECIMAL" />
    <result column="delete_state" property="deleteState" jdbcType="VARCHAR" />
    <result column="data_source" property="dataSource" jdbcType="VARCHAR" />
    <result column="updatetime" property="updatetime" jdbcType="TIMESTAMP" />
  </resultMap>
  <sql id="Example_Where_Clause" >
    <where >
      <foreach collection="oredCriteria" item="criteria" separator="or" >
        <if test="criteria.valid" >
          <trim prefix="(" suffix=")" prefixOverrides="and" >
            <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 collection="criterion.value" item="listItem" open="(" close=")" 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="(" suffix=")" prefixOverrides="and" >
            <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 collection="criterion.value" item="listItem" open="(" close=")" separator="," >
                    #{listItem}
                  </foreach>
                </when>
              </choose>
            </foreach>
          </trim>
        </if>
      </foreach>
    </where>
  </sql>
  <sql id="Base_Column_List" >
    id, fumigation_id, first_use_drug_time, first_use_drug_unit, first_use_drug_count, 
    circulation_use_time, first_supplement_drug_time, first_supplement_drug_count, last_supplement_drug_time, 
    last_supplement_drug_count, total_supplement_drug_times, total_supplement_drug_count, 
    total_use_drug_count, supplement_drug_type, is_circulation_fine, is_use_drug_equipment_fine, 
    is_house_tightness_fine, is_aerial_work_platform_fine, is_phosphine_detector_fine, 
    is_phosphine_alarm_fine, is_oxygen_detector_fine, is_air_respirator_fine, is_have_warning_sign_fine, 
    is_fire_extinguisher_fine, is_have_first_aid_kit, bulk_start_time, bulk_end_time, 
    bulk_gas_type, bulk_end_toxic_gas_concentration, drug_residue_rate, dcsqtinfo_id, 
    task_state, task_end_time, creater, create_time, update_time, org_id, yqbjyaqjc, 
    byqcnlhqnd, mbnd, jsbyl, byzypzr, fznd, mbndwcts, lswzjc, lqbwcqdbjcs, mbsj, ctz, 
    sqqlhqnd, sqpzr, sqcsts, sqjsslhqnd, delete_state, data_source, updatetime
  </sql>
  <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcessExample" >
    select
    <if test="distinct" >
      distinct
    </if>
    <include refid="Base_Column_List" />
    from t_fumigation_process
    <if test="_parameter != null" >
      <include refid="Example_Where_Clause" />
    </if>
    <if test="orderByClause != null" >
      order by ${orderByClause}
    </if>
  </select>
  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
    select 
    <include refid="Base_Column_List" />
    from t_fumigation_process
    where id = #{id,jdbcType=VARCHAR}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
    delete from t_fumigation_process
    where id = #{id,jdbcType=VARCHAR}
  </delete>
  <delete id="deleteByExample" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcessExample" >
    delete from t_fumigation_process
    <if test="_parameter != null" >
      <include refid="Example_Where_Clause" />
    </if>
  </delete>
  <insert id="insert" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcess" >
    insert into t_fumigation_process (id, fumigation_id, first_use_drug_time, 
      first_use_drug_unit, first_use_drug_count, circulation_use_time, 
      first_supplement_drug_time, first_supplement_drug_count, 
      last_supplement_drug_time, last_supplement_drug_count, 
      total_supplement_drug_times, total_supplement_drug_count, 
      total_use_drug_count, supplement_drug_type, 
      is_circulation_fine, is_use_drug_equipment_fine, 
      is_house_tightness_fine, is_aerial_work_platform_fine, 
      is_phosphine_detector_fine, is_phosphine_alarm_fine, 
      is_oxygen_detector_fine, is_air_respirator_fine, 
      is_have_warning_sign_fine, is_fire_extinguisher_fine, 
      is_have_first_aid_kit, bulk_start_time, bulk_end_time, 
      bulk_gas_type, bulk_end_toxic_gas_concentration, 
      drug_residue_rate, dcsqtinfo_id, task_state, 
      task_end_time, creater, create_time, 
      update_time, org_id, yqbjyaqjc, 
      byqcnlhqnd, mbnd, jsbyl, 
      byzypzr, fznd, mbndwcts, 
      lswzjc, lqbwcqdbjcs, mbsj, 
      ctz, sqqlhqnd, sqpzr, 
      sqcsts, sqjsslhqnd, delete_state, 
      data_source, updatetime)
    values (#{id,jdbcType=VARCHAR}, #{fumigationId,jdbcType=VARCHAR}, #{firstUseDrugTime,jdbcType=TIMESTAMP}, 
      #{firstUseDrugUnit,jdbcType=VARCHAR}, #{firstUseDrugCount,jdbcType=VARCHAR}, #{circulationUseTime,jdbcType=VARCHAR}, 
      #{firstSupplementDrugTime,jdbcType=TIMESTAMP}, #{firstSupplementDrugCount,jdbcType=VARCHAR}, 
      #{lastSupplementDrugTime,jdbcType=TIMESTAMP}, #{lastSupplementDrugCount,jdbcType=VARCHAR}, 
      #{totalSupplementDrugTimes,jdbcType=INTEGER}, #{totalSupplementDrugCount,jdbcType=VARCHAR}, 
      #{totalUseDrugCount,jdbcType=VARCHAR}, #{supplementDrugType,jdbcType=VARCHAR}, 
      #{isCirculationFine,jdbcType=INTEGER}, #{isUseDrugEquipmentFine,jdbcType=INTEGER}, 
      #{isHouseTightnessFine,jdbcType=INTEGER}, #{isAerialWorkPlatformFine,jdbcType=INTEGER}, 
      #{isPhosphineDetectorFine,jdbcType=INTEGER}, #{isPhosphineAlarmFine,jdbcType=INTEGER}, 
      #{isOxygenDetectorFine,jdbcType=INTEGER}, #{isAirRespiratorFine,jdbcType=INTEGER}, 
      #{isHaveWarningSignFine,jdbcType=INTEGER}, #{isFireExtinguisherFine,jdbcType=INTEGER}, 
      #{isHaveFirstAidKit,jdbcType=INTEGER}, #{bulkStartTime,jdbcType=TIMESTAMP}, #{bulkEndTime,jdbcType=TIMESTAMP}, 
      #{bulkGasType,jdbcType=VARCHAR}, #{bulkEndToxicGasConcentration,jdbcType=VARCHAR}, 
      #{drugResidueRate,jdbcType=VARCHAR}, #{dcsqtinfoId,jdbcType=VARCHAR}, #{taskState,jdbcType=INTEGER}, 
      #{taskEndTime,jdbcType=TIMESTAMP}, #{creater,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, 
      #{updateTime,jdbcType=TIMESTAMP}, #{orgId,jdbcType=INTEGER}, #{yqbjyaqjc,jdbcType=VARCHAR}, 
      #{byqcnlhqnd,jdbcType=DECIMAL}, #{mbnd,jdbcType=DECIMAL}, #{jsbyl,jdbcType=DECIMAL}, 
      #{byzypzr,jdbcType=VARCHAR}, #{fznd,jdbcType=DECIMAL}, #{mbndwcts,jdbcType=INTEGER}, 
      #{lswzjc,jdbcType=VARCHAR}, #{lqbwcqdbjcs,jdbcType=VARCHAR}, #{mbsj,jdbcType=INTEGER}, 
      #{ctz,jdbcType=DECIMAL}, #{sqqlhqnd,jdbcType=DECIMAL}, #{sqpzr,jdbcType=VARCHAR}, 
      #{sqcsts,jdbcType=INTEGER}, #{sqjsslhqnd,jdbcType=DECIMAL}, #{deleteState,jdbcType=VARCHAR}, 
      #{dataSource,jdbcType=VARCHAR}, #{updatetime,jdbcType=TIMESTAMP})
  </insert>
  <insert id="insertSelective" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcess" >
    insert into t_fumigation_process
    <trim prefix="(" suffix=")" suffixOverrides="," >
      <if test="id != null" >
        id,
      </if>
      <if test="fumigationId != null" >
        fumigation_id,
      </if>
      <if test="firstUseDrugTime != null" >
        first_use_drug_time,
      </if>
      <if test="firstUseDrugUnit != null" >
        first_use_drug_unit,
      </if>
      <if test="firstUseDrugCount != null" >
        first_use_drug_count,
      </if>
      <if test="circulationUseTime != null" >
        circulation_use_time,
      </if>
      <if test="firstSupplementDrugTime != null" >
        first_supplement_drug_time,
      </if>
      <if test="firstSupplementDrugCount != null" >
        first_supplement_drug_count,
      </if>
      <if test="lastSupplementDrugTime != null" >
        last_supplement_drug_time,
      </if>
      <if test="lastSupplementDrugCount != null" >
        last_supplement_drug_count,
      </if>
      <if test="totalSupplementDrugTimes != null" >
        total_supplement_drug_times,
      </if>
      <if test="totalSupplementDrugCount != null" >
        total_supplement_drug_count,
      </if>
      <if test="totalUseDrugCount != null" >
        total_use_drug_count,
      </if>
      <if test="supplementDrugType != null" >
        supplement_drug_type,
      </if>
      <if test="isCirculationFine != null" >
        is_circulation_fine,
      </if>
      <if test="isUseDrugEquipmentFine != null" >
        is_use_drug_equipment_fine,
      </if>
      <if test="isHouseTightnessFine != null" >
        is_house_tightness_fine,
      </if>
      <if test="isAerialWorkPlatformFine != null" >
        is_aerial_work_platform_fine,
      </if>
      <if test="isPhosphineDetectorFine != null" >
        is_phosphine_detector_fine,
      </if>
      <if test="isPhosphineAlarmFine != null" >
        is_phosphine_alarm_fine,
      </if>
      <if test="isOxygenDetectorFine != null" >
        is_oxygen_detector_fine,
      </if>
      <if test="isAirRespiratorFine != null" >
        is_air_respirator_fine,
      </if>
      <if test="isHaveWarningSignFine != null" >
        is_have_warning_sign_fine,
      </if>
      <if test="isFireExtinguisherFine != null" >
        is_fire_extinguisher_fine,
      </if>
      <if test="isHaveFirstAidKit != null" >
        is_have_first_aid_kit,
      </if>
      <if test="bulkStartTime != null" >
        bulk_start_time,
      </if>
      <if test="bulkEndTime != null" >
        bulk_end_time,
      </if>
      <if test="bulkGasType != null" >
        bulk_gas_type,
      </if>
      <if test="bulkEndToxicGasConcentration != null" >
        bulk_end_toxic_gas_concentration,
      </if>
      <if test="drugResidueRate != null" >
        drug_residue_rate,
      </if>
      <if test="dcsqtinfoId != null" >
        dcsqtinfo_id,
      </if>
      <if test="taskState != null" >
        task_state,
      </if>
      <if test="taskEndTime != null" >
        task_end_time,
      </if>
      <if test="creater != null" >
        creater,
      </if>
      <if test="createTime != null" >
        create_time,
      </if>
      <if test="updateTime != null" >
        update_time,
      </if>
      <if test="orgId != null" >
        org_id,
      </if>
      <if test="yqbjyaqjc != null" >
        yqbjyaqjc,
      </if>
      <if test="byqcnlhqnd != null" >
        byqcnlhqnd,
      </if>
      <if test="mbnd != null" >
        mbnd,
      </if>
      <if test="jsbyl != null" >
        jsbyl,
      </if>
      <if test="byzypzr != null" >
        byzypzr,
      </if>
      <if test="fznd != null" >
        fznd,
      </if>
      <if test="mbndwcts != null" >
        mbndwcts,
      </if>
      <if test="lswzjc != null" >
        lswzjc,
      </if>
      <if test="lqbwcqdbjcs != null" >
        lqbwcqdbjcs,
      </if>
      <if test="mbsj != null" >
        mbsj,
      </if>
      <if test="ctz != null" >
        ctz,
      </if>
      <if test="sqqlhqnd != null" >
        sqqlhqnd,
      </if>
      <if test="sqpzr != null" >
        sqpzr,
      </if>
      <if test="sqcsts != null" >
        sqcsts,
      </if>
      <if test="sqjsslhqnd != null" >
        sqjsslhqnd,
      </if>
      <if test="deleteState != null" >
        delete_state,
      </if>
      <if test="dataSource != null" >
        data_source,
      </if>
      <if test="updatetime != null" >
        updatetime,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides="," >
      <if test="id != null" >
        #{id,jdbcType=VARCHAR},
      </if>
      <if test="fumigationId != null" >
        #{fumigationId,jdbcType=VARCHAR},
      </if>
      <if test="firstUseDrugTime != null" >
        #{firstUseDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="firstUseDrugUnit != null" >
        #{firstUseDrugUnit,jdbcType=VARCHAR},
      </if>
      <if test="firstUseDrugCount != null" >
        #{firstUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="circulationUseTime != null" >
        #{circulationUseTime,jdbcType=VARCHAR},
      </if>
      <if test="firstSupplementDrugTime != null" >
        #{firstSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="firstSupplementDrugCount != null" >
        #{firstSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="lastSupplementDrugTime != null" >
        #{lastSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="lastSupplementDrugCount != null" >
        #{lastSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="totalSupplementDrugTimes != null" >
        #{totalSupplementDrugTimes,jdbcType=INTEGER},
      </if>
      <if test="totalSupplementDrugCount != null" >
        #{totalSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="totalUseDrugCount != null" >
        #{totalUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="supplementDrugType != null" >
        #{supplementDrugType,jdbcType=VARCHAR},
      </if>
      <if test="isCirculationFine != null" >
        #{isCirculationFine,jdbcType=INTEGER},
      </if>
      <if test="isUseDrugEquipmentFine != null" >
        #{isUseDrugEquipmentFine,jdbcType=INTEGER},
      </if>
      <if test="isHouseTightnessFine != null" >
        #{isHouseTightnessFine,jdbcType=INTEGER},
      </if>
      <if test="isAerialWorkPlatformFine != null" >
        #{isAerialWorkPlatformFine,jdbcType=INTEGER},
      </if>
      <if test="isPhosphineDetectorFine != null" >
        #{isPhosphineDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="isPhosphineAlarmFine != null" >
        #{isPhosphineAlarmFine,jdbcType=INTEGER},
      </if>
      <if test="isOxygenDetectorFine != null" >
        #{isOxygenDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="isAirRespiratorFine != null" >
        #{isAirRespiratorFine,jdbcType=INTEGER},
      </if>
      <if test="isHaveWarningSignFine != null" >
        #{isHaveWarningSignFine,jdbcType=INTEGER},
      </if>
      <if test="isFireExtinguisherFine != null" >
        #{isFireExtinguisherFine,jdbcType=INTEGER},
      </if>
      <if test="isHaveFirstAidKit != null" >
        #{isHaveFirstAidKit,jdbcType=INTEGER},
      </if>
      <if test="bulkStartTime != null" >
        #{bulkStartTime,jdbcType=TIMESTAMP},
      </if>
      <if test="bulkEndTime != null" >
        #{bulkEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="bulkGasType != null" >
        #{bulkGasType,jdbcType=VARCHAR},
      </if>
      <if test="bulkEndToxicGasConcentration != null" >
        #{bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      </if>
      <if test="drugResidueRate != null" >
        #{drugResidueRate,jdbcType=VARCHAR},
      </if>
      <if test="dcsqtinfoId != null" >
        #{dcsqtinfoId,jdbcType=VARCHAR},
      </if>
      <if test="taskState != null" >
        #{taskState,jdbcType=INTEGER},
      </if>
      <if test="taskEndTime != null" >
        #{taskEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="creater != null" >
        #{creater,jdbcType=INTEGER},
      </if>
      <if test="createTime != null" >
        #{createTime,jdbcType=TIMESTAMP},
      </if>
      <if test="updateTime != null" >
        #{updateTime,jdbcType=TIMESTAMP},
      </if>
      <if test="orgId != null" >
        #{orgId,jdbcType=INTEGER},
      </if>
      <if test="yqbjyaqjc != null" >
        #{yqbjyaqjc,jdbcType=VARCHAR},
      </if>
      <if test="byqcnlhqnd != null" >
        #{byqcnlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="mbnd != null" >
        #{mbnd,jdbcType=DECIMAL},
      </if>
      <if test="jsbyl != null" >
        #{jsbyl,jdbcType=DECIMAL},
      </if>
      <if test="byzypzr != null" >
        #{byzypzr,jdbcType=VARCHAR},
      </if>
      <if test="fznd != null" >
        #{fznd,jdbcType=DECIMAL},
      </if>
      <if test="mbndwcts != null" >
        #{mbndwcts,jdbcType=INTEGER},
      </if>
      <if test="lswzjc != null" >
        #{lswzjc,jdbcType=VARCHAR},
      </if>
      <if test="lqbwcqdbjcs != null" >
        #{lqbwcqdbjcs,jdbcType=VARCHAR},
      </if>
      <if test="mbsj != null" >
        #{mbsj,jdbcType=INTEGER},
      </if>
      <if test="ctz != null" >
        #{ctz,jdbcType=DECIMAL},
      </if>
      <if test="sqqlhqnd != null" >
        #{sqqlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="sqpzr != null" >
        #{sqpzr,jdbcType=VARCHAR},
      </if>
      <if test="sqcsts != null" >
        #{sqcsts,jdbcType=INTEGER},
      </if>
      <if test="sqjsslhqnd != null" >
        #{sqjsslhqnd,jdbcType=DECIMAL},
      </if>
      <if test="deleteState != null" >
        #{deleteState,jdbcType=VARCHAR},
      </if>
      <if test="dataSource != null" >
        #{dataSource,jdbcType=VARCHAR},
      </if>
      <if test="updatetime != null" >
        #{updatetime,jdbcType=TIMESTAMP},
      </if>
    </trim>
  </insert>
  <select id="countByExample" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcessExample" resultType="java.lang.Integer" >
    select count(*) from t_fumigation_process
    <if test="_parameter != null" >
      <include refid="Example_Where_Clause" />
    </if>
  </select>
  <update id="updateByExampleSelective" parameterType="map" >
    update t_fumigation_process
    <set >
      <if test="record.id != null" >
        id = #{record.id,jdbcType=VARCHAR},
      </if>
      <if test="record.fumigationId != null" >
        fumigation_id = #{record.fumigationId,jdbcType=VARCHAR},
      </if>
      <if test="record.firstUseDrugTime != null" >
        first_use_drug_time = #{record.firstUseDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.firstUseDrugUnit != null" >
        first_use_drug_unit = #{record.firstUseDrugUnit,jdbcType=VARCHAR},
      </if>
      <if test="record.firstUseDrugCount != null" >
        first_use_drug_count = #{record.firstUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="record.circulationUseTime != null" >
        circulation_use_time = #{record.circulationUseTime,jdbcType=VARCHAR},
      </if>
      <if test="record.firstSupplementDrugTime != null" >
        first_supplement_drug_time = #{record.firstSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.firstSupplementDrugCount != null" >
        first_supplement_drug_count = #{record.firstSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="record.lastSupplementDrugTime != null" >
        last_supplement_drug_time = #{record.lastSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.lastSupplementDrugCount != null" >
        last_supplement_drug_count = #{record.lastSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="record.totalSupplementDrugTimes != null" >
        total_supplement_drug_times = #{record.totalSupplementDrugTimes,jdbcType=INTEGER},
      </if>
      <if test="record.totalSupplementDrugCount != null" >
        total_supplement_drug_count = #{record.totalSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="record.totalUseDrugCount != null" >
        total_use_drug_count = #{record.totalUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="record.supplementDrugType != null" >
        supplement_drug_type = #{record.supplementDrugType,jdbcType=VARCHAR},
      </if>
      <if test="record.isCirculationFine != null" >
        is_circulation_fine = #{record.isCirculationFine,jdbcType=INTEGER},
      </if>
      <if test="record.isUseDrugEquipmentFine != null" >
        is_use_drug_equipment_fine = #{record.isUseDrugEquipmentFine,jdbcType=INTEGER},
      </if>
      <if test="record.isHouseTightnessFine != null" >
        is_house_tightness_fine = #{record.isHouseTightnessFine,jdbcType=INTEGER},
      </if>
      <if test="record.isAerialWorkPlatformFine != null" >
        is_aerial_work_platform_fine = #{record.isAerialWorkPlatformFine,jdbcType=INTEGER},
      </if>
      <if test="record.isPhosphineDetectorFine != null" >
        is_phosphine_detector_fine = #{record.isPhosphineDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="record.isPhosphineAlarmFine != null" >
        is_phosphine_alarm_fine = #{record.isPhosphineAlarmFine,jdbcType=INTEGER},
      </if>
      <if test="record.isOxygenDetectorFine != null" >
        is_oxygen_detector_fine = #{record.isOxygenDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="record.isAirRespiratorFine != null" >
        is_air_respirator_fine = #{record.isAirRespiratorFine,jdbcType=INTEGER},
      </if>
      <if test="record.isHaveWarningSignFine != null" >
        is_have_warning_sign_fine = #{record.isHaveWarningSignFine,jdbcType=INTEGER},
      </if>
      <if test="record.isFireExtinguisherFine != null" >
        is_fire_extinguisher_fine = #{record.isFireExtinguisherFine,jdbcType=INTEGER},
      </if>
      <if test="record.isHaveFirstAidKit != null" >
        is_have_first_aid_kit = #{record.isHaveFirstAidKit,jdbcType=INTEGER},
      </if>
      <if test="record.bulkStartTime != null" >
        bulk_start_time = #{record.bulkStartTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.bulkEndTime != null" >
        bulk_end_time = #{record.bulkEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.bulkGasType != null" >
        bulk_gas_type = #{record.bulkGasType,jdbcType=VARCHAR},
      </if>
      <if test="record.bulkEndToxicGasConcentration != null" >
        bulk_end_toxic_gas_concentration = #{record.bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      </if>
      <if test="record.drugResidueRate != null" >
        drug_residue_rate = #{record.drugResidueRate,jdbcType=VARCHAR},
      </if>
      <if test="record.dcsqtinfoId != null" >
        dcsqtinfo_id = #{record.dcsqtinfoId,jdbcType=VARCHAR},
      </if>
      <if test="record.taskState != null" >
        task_state = #{record.taskState,jdbcType=INTEGER},
      </if>
      <if test="record.taskEndTime != null" >
        task_end_time = #{record.taskEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.creater != null" >
        creater = #{record.creater,jdbcType=INTEGER},
      </if>
      <if test="record.createTime != null" >
        create_time = #{record.createTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.updateTime != null" >
        update_time = #{record.updateTime,jdbcType=TIMESTAMP},
      </if>
      <if test="record.orgId != null" >
        org_id = #{record.orgId,jdbcType=INTEGER},
      </if>
      <if test="record.yqbjyaqjc != null" >
        yqbjyaqjc = #{record.yqbjyaqjc,jdbcType=VARCHAR},
      </if>
      <if test="record.byqcnlhqnd != null" >
        byqcnlhqnd = #{record.byqcnlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="record.mbnd != null" >
        mbnd = #{record.mbnd,jdbcType=DECIMAL},
      </if>
      <if test="record.jsbyl != null" >
        jsbyl = #{record.jsbyl,jdbcType=DECIMAL},
      </if>
      <if test="record.byzypzr != null" >
        byzypzr = #{record.byzypzr,jdbcType=VARCHAR},
      </if>
      <if test="record.fznd != null" >
        fznd = #{record.fznd,jdbcType=DECIMAL},
      </if>
      <if test="record.mbndwcts != null" >
        mbndwcts = #{record.mbndwcts,jdbcType=INTEGER},
      </if>
      <if test="record.lswzjc != null" >
        lswzjc = #{record.lswzjc,jdbcType=VARCHAR},
      </if>
      <if test="record.lqbwcqdbjcs != null" >
        lqbwcqdbjcs = #{record.lqbwcqdbjcs,jdbcType=VARCHAR},
      </if>
      <if test="record.mbsj != null" >
        mbsj = #{record.mbsj,jdbcType=INTEGER},
      </if>
      <if test="record.ctz != null" >
        ctz = #{record.ctz,jdbcType=DECIMAL},
      </if>
      <if test="record.sqqlhqnd != null" >
        sqqlhqnd = #{record.sqqlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="record.sqpzr != null" >
        sqpzr = #{record.sqpzr,jdbcType=VARCHAR},
      </if>
      <if test="record.sqcsts != null" >
        sqcsts = #{record.sqcsts,jdbcType=INTEGER},
      </if>
      <if test="record.sqjsslhqnd != null" >
        sqjsslhqnd = #{record.sqjsslhqnd,jdbcType=DECIMAL},
      </if>
      <if test="record.deleteState != null" >
        delete_state = #{record.deleteState,jdbcType=VARCHAR},
      </if>
      <if test="record.dataSource != null" >
        data_source = #{record.dataSource,jdbcType=VARCHAR},
      </if>
      <if test="record.updatetime != null" >
        updatetime = #{record.updatetime,jdbcType=TIMESTAMP},
      </if>
    </set>
    <if test="_parameter != null" >
      <include refid="Update_By_Example_Where_Clause" />
    </if>
  </update>
  <update id="updateByExample" parameterType="map" >
    update t_fumigation_process
    set id = #{record.id,jdbcType=VARCHAR},
      fumigation_id = #{record.fumigationId,jdbcType=VARCHAR},
      first_use_drug_time = #{record.firstUseDrugTime,jdbcType=TIMESTAMP},
      first_use_drug_unit = #{record.firstUseDrugUnit,jdbcType=VARCHAR},
      first_use_drug_count = #{record.firstUseDrugCount,jdbcType=VARCHAR},
      circulation_use_time = #{record.circulationUseTime,jdbcType=VARCHAR},
      first_supplement_drug_time = #{record.firstSupplementDrugTime,jdbcType=TIMESTAMP},
      first_supplement_drug_count = #{record.firstSupplementDrugCount,jdbcType=VARCHAR},
      last_supplement_drug_time = #{record.lastSupplementDrugTime,jdbcType=TIMESTAMP},
      last_supplement_drug_count = #{record.lastSupplementDrugCount,jdbcType=VARCHAR},
      total_supplement_drug_times = #{record.totalSupplementDrugTimes,jdbcType=INTEGER},
      total_supplement_drug_count = #{record.totalSupplementDrugCount,jdbcType=VARCHAR},
      total_use_drug_count = #{record.totalUseDrugCount,jdbcType=VARCHAR},
      supplement_drug_type = #{record.supplementDrugType,jdbcType=VARCHAR},
      is_circulation_fine = #{record.isCirculationFine,jdbcType=INTEGER},
      is_use_drug_equipment_fine = #{record.isUseDrugEquipmentFine,jdbcType=INTEGER},
      is_house_tightness_fine = #{record.isHouseTightnessFine,jdbcType=INTEGER},
      is_aerial_work_platform_fine = #{record.isAerialWorkPlatformFine,jdbcType=INTEGER},
      is_phosphine_detector_fine = #{record.isPhosphineDetectorFine,jdbcType=INTEGER},
      is_phosphine_alarm_fine = #{record.isPhosphineAlarmFine,jdbcType=INTEGER},
      is_oxygen_detector_fine = #{record.isOxygenDetectorFine,jdbcType=INTEGER},
      is_air_respirator_fine = #{record.isAirRespiratorFine,jdbcType=INTEGER},
      is_have_warning_sign_fine = #{record.isHaveWarningSignFine,jdbcType=INTEGER},
      is_fire_extinguisher_fine = #{record.isFireExtinguisherFine,jdbcType=INTEGER},
      is_have_first_aid_kit = #{record.isHaveFirstAidKit,jdbcType=INTEGER},
      bulk_start_time = #{record.bulkStartTime,jdbcType=TIMESTAMP},
      bulk_end_time = #{record.bulkEndTime,jdbcType=TIMESTAMP},
      bulk_gas_type = #{record.bulkGasType,jdbcType=VARCHAR},
      bulk_end_toxic_gas_concentration = #{record.bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      drug_residue_rate = #{record.drugResidueRate,jdbcType=VARCHAR},
      dcsqtinfo_id = #{record.dcsqtinfoId,jdbcType=VARCHAR},
      task_state = #{record.taskState,jdbcType=INTEGER},
      task_end_time = #{record.taskEndTime,jdbcType=TIMESTAMP},
      creater = #{record.creater,jdbcType=INTEGER},
      create_time = #{record.createTime,jdbcType=TIMESTAMP},
      update_time = #{record.updateTime,jdbcType=TIMESTAMP},
      org_id = #{record.orgId,jdbcType=INTEGER},
      yqbjyaqjc = #{record.yqbjyaqjc,jdbcType=VARCHAR},
      byqcnlhqnd = #{record.byqcnlhqnd,jdbcType=DECIMAL},
      mbnd = #{record.mbnd,jdbcType=DECIMAL},
      jsbyl = #{record.jsbyl,jdbcType=DECIMAL},
      byzypzr = #{record.byzypzr,jdbcType=VARCHAR},
      fznd = #{record.fznd,jdbcType=DECIMAL},
      mbndwcts = #{record.mbndwcts,jdbcType=INTEGER},
      lswzjc = #{record.lswzjc,jdbcType=VARCHAR},
      lqbwcqdbjcs = #{record.lqbwcqdbjcs,jdbcType=VARCHAR},
      mbsj = #{record.mbsj,jdbcType=INTEGER},
      ctz = #{record.ctz,jdbcType=DECIMAL},
      sqqlhqnd = #{record.sqqlhqnd,jdbcType=DECIMAL},
      sqpzr = #{record.sqpzr,jdbcType=VARCHAR},
      sqcsts = #{record.sqcsts,jdbcType=INTEGER},
      sqjsslhqnd = #{record.sqjsslhqnd,jdbcType=DECIMAL},
      delete_state = #{record.deleteState,jdbcType=VARCHAR},
      data_source = #{record.dataSource,jdbcType=VARCHAR},
      updatetime = #{record.updatetime,jdbcType=TIMESTAMP}
    <if test="_parameter != null" >
      <include refid="Update_By_Example_Where_Clause" />
    </if>
  </update>
  <update id="updateByPrimaryKeySelective" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcess" >
    update t_fumigation_process
    <set >
      <if test="fumigationId != null" >
        fumigation_id = #{fumigationId,jdbcType=VARCHAR},
      </if>
      <if test="firstUseDrugTime != null" >
        first_use_drug_time = #{firstUseDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="firstUseDrugUnit != null" >
        first_use_drug_unit = #{firstUseDrugUnit,jdbcType=VARCHAR},
      </if>
      <if test="firstUseDrugCount != null" >
        first_use_drug_count = #{firstUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="circulationUseTime != null" >
        circulation_use_time = #{circulationUseTime,jdbcType=VARCHAR},
      </if>
      <if test="firstSupplementDrugTime != null" >
        first_supplement_drug_time = #{firstSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="firstSupplementDrugCount != null" >
        first_supplement_drug_count = #{firstSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="lastSupplementDrugTime != null" >
        last_supplement_drug_time = #{lastSupplementDrugTime,jdbcType=TIMESTAMP},
      </if>
      <if test="lastSupplementDrugCount != null" >
        last_supplement_drug_count = #{lastSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="totalSupplementDrugTimes != null" >
        total_supplement_drug_times = #{totalSupplementDrugTimes,jdbcType=INTEGER},
      </if>
      <if test="totalSupplementDrugCount != null" >
        total_supplement_drug_count = #{totalSupplementDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="totalUseDrugCount != null" >
        total_use_drug_count = #{totalUseDrugCount,jdbcType=VARCHAR},
      </if>
      <if test="supplementDrugType != null" >
        supplement_drug_type = #{supplementDrugType,jdbcType=VARCHAR},
      </if>
      <if test="isCirculationFine != null" >
        is_circulation_fine = #{isCirculationFine,jdbcType=INTEGER},
      </if>
      <if test="isUseDrugEquipmentFine != null" >
        is_use_drug_equipment_fine = #{isUseDrugEquipmentFine,jdbcType=INTEGER},
      </if>
      <if test="isHouseTightnessFine != null" >
        is_house_tightness_fine = #{isHouseTightnessFine,jdbcType=INTEGER},
      </if>
      <if test="isAerialWorkPlatformFine != null" >
        is_aerial_work_platform_fine = #{isAerialWorkPlatformFine,jdbcType=INTEGER},
      </if>
      <if test="isPhosphineDetectorFine != null" >
        is_phosphine_detector_fine = #{isPhosphineDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="isPhosphineAlarmFine != null" >
        is_phosphine_alarm_fine = #{isPhosphineAlarmFine,jdbcType=INTEGER},
      </if>
      <if test="isOxygenDetectorFine != null" >
        is_oxygen_detector_fine = #{isOxygenDetectorFine,jdbcType=INTEGER},
      </if>
      <if test="isAirRespiratorFine != null" >
        is_air_respirator_fine = #{isAirRespiratorFine,jdbcType=INTEGER},
      </if>
      <if test="isHaveWarningSignFine != null" >
        is_have_warning_sign_fine = #{isHaveWarningSignFine,jdbcType=INTEGER},
      </if>
      <if test="isFireExtinguisherFine != null" >
        is_fire_extinguisher_fine = #{isFireExtinguisherFine,jdbcType=INTEGER},
      </if>
      <if test="isHaveFirstAidKit != null" >
        is_have_first_aid_kit = #{isHaveFirstAidKit,jdbcType=INTEGER},
      </if>
      <if test="bulkStartTime != null" >
        bulk_start_time = #{bulkStartTime,jdbcType=TIMESTAMP},
      </if>
      <if test="bulkEndTime != null" >
        bulk_end_time = #{bulkEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="bulkGasType != null" >
        bulk_gas_type = #{bulkGasType,jdbcType=VARCHAR},
      </if>
      <if test="bulkEndToxicGasConcentration != null" >
        bulk_end_toxic_gas_concentration = #{bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      </if>
      <if test="drugResidueRate != null" >
        drug_residue_rate = #{drugResidueRate,jdbcType=VARCHAR},
      </if>
      <if test="dcsqtinfoId != null" >
        dcsqtinfo_id = #{dcsqtinfoId,jdbcType=VARCHAR},
      </if>
      <if test="taskState != null" >
        task_state = #{taskState,jdbcType=INTEGER},
      </if>
      <if test="taskEndTime != null" >
        task_end_time = #{taskEndTime,jdbcType=TIMESTAMP},
      </if>
      <if test="creater != null" >
        creater = #{creater,jdbcType=INTEGER},
      </if>
      <if test="createTime != null" >
        create_time = #{createTime,jdbcType=TIMESTAMP},
      </if>
      <if test="updateTime != null" >
        update_time = #{updateTime,jdbcType=TIMESTAMP},
      </if>
      <if test="orgId != null" >
        org_id = #{orgId,jdbcType=INTEGER},
      </if>
      <if test="yqbjyaqjc != null" >
        yqbjyaqjc = #{yqbjyaqjc,jdbcType=VARCHAR},
      </if>
      <if test="byqcnlhqnd != null" >
        byqcnlhqnd = #{byqcnlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="mbnd != null" >
        mbnd = #{mbnd,jdbcType=DECIMAL},
      </if>
      <if test="jsbyl != null" >
        jsbyl = #{jsbyl,jdbcType=DECIMAL},
      </if>
      <if test="byzypzr != null" >
        byzypzr = #{byzypzr,jdbcType=VARCHAR},
      </if>
      <if test="fznd != null" >
        fznd = #{fznd,jdbcType=DECIMAL},
      </if>
      <if test="mbndwcts != null" >
        mbndwcts = #{mbndwcts,jdbcType=INTEGER},
      </if>
      <if test="lswzjc != null" >
        lswzjc = #{lswzjc,jdbcType=VARCHAR},
      </if>
      <if test="lqbwcqdbjcs != null" >
        lqbwcqdbjcs = #{lqbwcqdbjcs,jdbcType=VARCHAR},
      </if>
      <if test="mbsj != null" >
        mbsj = #{mbsj,jdbcType=INTEGER},
      </if>
      <if test="ctz != null" >
        ctz = #{ctz,jdbcType=DECIMAL},
      </if>
      <if test="sqqlhqnd != null" >
        sqqlhqnd = #{sqqlhqnd,jdbcType=DECIMAL},
      </if>
      <if test="sqpzr != null" >
        sqpzr = #{sqpzr,jdbcType=VARCHAR},
      </if>
      <if test="sqcsts != null" >
        sqcsts = #{sqcsts,jdbcType=INTEGER},
      </if>
      <if test="sqjsslhqnd != null" >
        sqjsslhqnd = #{sqjsslhqnd,jdbcType=DECIMAL},
      </if>
      <if test="deleteState != null" >
        delete_state = #{deleteState,jdbcType=VARCHAR},
      </if>
      <if test="dataSource != null" >
        data_source = #{dataSource,jdbcType=VARCHAR},
      </if>
      <if test="updatetime != null" >
        updatetime = #{updatetime,jdbcType=TIMESTAMP},
      </if>
    </set>
    where id = #{id,jdbcType=VARCHAR}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.chinaitop.depot.intelligent.fumigation.model.TFumigationProcess" >
    update t_fumigation_process
    set fumigation_id = #{fumigationId,jdbcType=VARCHAR},
      first_use_drug_time = #{firstUseDrugTime,jdbcType=TIMESTAMP},
      first_use_drug_unit = #{firstUseDrugUnit,jdbcType=VARCHAR},
      first_use_drug_count = #{firstUseDrugCount,jdbcType=VARCHAR},
      circulation_use_time = #{circulationUseTime,jdbcType=VARCHAR},
      first_supplement_drug_time = #{firstSupplementDrugTime,jdbcType=TIMESTAMP},
      first_supplement_drug_count = #{firstSupplementDrugCount,jdbcType=VARCHAR},
      last_supplement_drug_time = #{lastSupplementDrugTime,jdbcType=TIMESTAMP},
      last_supplement_drug_count = #{lastSupplementDrugCount,jdbcType=VARCHAR},
      total_supplement_drug_times = #{totalSupplementDrugTimes,jdbcType=INTEGER},
      total_supplement_drug_count = #{totalSupplementDrugCount,jdbcType=VARCHAR},
      total_use_drug_count = #{totalUseDrugCount,jdbcType=VARCHAR},
      supplement_drug_type = #{supplementDrugType,jdbcType=VARCHAR},
      is_circulation_fine = #{isCirculationFine,jdbcType=INTEGER},
      is_use_drug_equipment_fine = #{isUseDrugEquipmentFine,jdbcType=INTEGER},
      is_house_tightness_fine = #{isHouseTightnessFine,jdbcType=INTEGER},
      is_aerial_work_platform_fine = #{isAerialWorkPlatformFine,jdbcType=INTEGER},
      is_phosphine_detector_fine = #{isPhosphineDetectorFine,jdbcType=INTEGER},
      is_phosphine_alarm_fine = #{isPhosphineAlarmFine,jdbcType=INTEGER},
      is_oxygen_detector_fine = #{isOxygenDetectorFine,jdbcType=INTEGER},
      is_air_respirator_fine = #{isAirRespiratorFine,jdbcType=INTEGER},
      is_have_warning_sign_fine = #{isHaveWarningSignFine,jdbcType=INTEGER},
      is_fire_extinguisher_fine = #{isFireExtinguisherFine,jdbcType=INTEGER},
      is_have_first_aid_kit = #{isHaveFirstAidKit,jdbcType=INTEGER},
      bulk_start_time = #{bulkStartTime,jdbcType=TIMESTAMP},
      bulk_end_time = #{bulkEndTime,jdbcType=TIMESTAMP},
      bulk_gas_type = #{bulkGasType,jdbcType=VARCHAR},
      bulk_end_toxic_gas_concentration = #{bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      drug_residue_rate = #{drugResidueRate,jdbcType=VARCHAR},
      dcsqtinfo_id = #{dcsqtinfoId,jdbcType=VARCHAR},
      task_state = #{taskState,jdbcType=INTEGER},
      task_end_time = #{taskEndTime,jdbcType=TIMESTAMP},
      creater = #{creater,jdbcType=INTEGER},
      create_time = #{createTime,jdbcType=TIMESTAMP},
      update_time = #{updateTime,jdbcType=TIMESTAMP},
      org_id = #{orgId,jdbcType=INTEGER},
      yqbjyaqjc = #{yqbjyaqjc,jdbcType=VARCHAR},
      byqcnlhqnd = #{byqcnlhqnd,jdbcType=DECIMAL},
      mbnd = #{mbnd,jdbcType=DECIMAL},
      jsbyl = #{jsbyl,jdbcType=DECIMAL},
      byzypzr = #{byzypzr,jdbcType=VARCHAR},
      fznd = #{fznd,jdbcType=DECIMAL},
      mbndwcts = #{mbndwcts,jdbcType=INTEGER},
      lswzjc = #{lswzjc,jdbcType=VARCHAR},
      lqbwcqdbjcs = #{lqbwcqdbjcs,jdbcType=VARCHAR},
      mbsj = #{mbsj,jdbcType=INTEGER},
      ctz = #{ctz,jdbcType=DECIMAL},
      sqqlhqnd = #{sqqlhqnd,jdbcType=DECIMAL},
      sqpzr = #{sqpzr,jdbcType=VARCHAR},
      sqcsts = #{sqcsts,jdbcType=INTEGER},
      sqjsslhqnd = #{sqjsslhqnd,jdbcType=DECIMAL},
      delete_state = #{deleteState,jdbcType=VARCHAR},
      data_source = #{dataSource,jdbcType=VARCHAR},
      updatetime = #{updatetime,jdbcType=TIMESTAMP}
    where id = #{id,jdbcType=VARCHAR}
  </update>

  <select id="getPesticideProcessList" parameterType="java.util.Map" resultType="java.util.HashMap">
    SELECT
    pro.id,
    plan.id fumigationId,
    plan.house_id houseId,
    plan.grain_kind grainKind,
    pes.drug_name drugName,
    plan.fumigation_type fumigationType,
    plan.creater,
    plan.state,
    pro.task_end_time taskEndTime
    FROM
    t_fumigation_process pro
    INNER JOIN t_fumigation_plan plan ON pro.fumigation_id = plan.id
    LEFT JOIN t_fumigation_pesticide pes ON pes.fumigation_id = plan.id
    WHERE pro.delete_state = 1
    <if test="houseId != null" >
      AND plan.house_id = #{houseId,jdbcType=INTEGER}
    </if>
    <if test="orgId != null" >
      AND plan.org_id = #{orgId,jdbcType=INTEGER}
    </if>
    GROUP BY pro.id
    ORDER BY pro.create_time DESC
  </select>

  <insert id="insertBatch" parameterType="java.util.List">
    insert into t_fumigation_process (id, fumigation_id, first_use_drug_time,
    first_use_drug_unit, first_use_drug_count, circulation_use_time,
    first_supplement_drug_time, first_supplement_drug_count,
    last_supplement_drug_time, last_supplement_drug_count,
    total_supplement_drug_times, total_supplement_drug_count,
    total_use_drug_count, supplement_drug_type,
    is_circulation_fine, is_use_drug_equipment_fine,
    is_house_tightness_fine, is_aerial_work_platform_fine,
    is_phosphine_detector_fine, is_phosphine_alarm_fine,
    is_oxygen_detector_fine, is_air_respirator_fine,
    is_have_warning_sign_fine, is_fire_extinguisher_fine,
    is_have_first_aid_kit, bulk_start_time, bulk_end_time,
    bulk_gas_type, bulk_end_toxic_gas_concentration,
    drug_residue_rate, dcsqtinfo_id, task_state,
    task_end_time, creater, create_time,
    update_time, org_id, delete_state,
    data_source)
    values
    <foreach collection="list" item="process" index="index" separator=",">
      (#{process.id,jdbcType=INTEGER}, #{process.fumigationId,jdbcType=VARCHAR}, #{process.firstUseDrugTime,jdbcType=TIMESTAMP},
      #{process.firstUseDrugUnit,jdbcType=VARCHAR}, #{process.firstUseDrugCount,jdbcType=VARCHAR}, #{process.circulationUseTime,jdbcType=VARCHAR},
      #{process.firstSupplementDrugTime,jdbcType=TIMESTAMP}, #{process.firstSupplementDrugCount,jdbcType=VARCHAR},
      #{process.lastSupplementDrugTime,jdbcType=TIMESTAMP}, #{process.lastSupplementDrugCount,jdbcType=VARCHAR},
      #{process.totalSupplementDrugTimes,jdbcType=INTEGER}, #{process.totalSupplementDrugCount,jdbcType=VARCHAR},
      #{process.totalUseDrugCount,jdbcType=VARCHAR}, #{process.supplementDrugType,jdbcType=VARCHAR},
      #{process.isCirculationFine,jdbcType=INTEGER}, #{process.isUseDrugEquipmentFine,jdbcType=INTEGER},
      #{process.isHouseTightnessFine,jdbcType=INTEGER}, #{process.isAerialWorkPlatformFine,jdbcType=INTEGER},
      #{process.isPhosphineDetectorFine,jdbcType=INTEGER}, #{process.isPhosphineAlarmFine,jdbcType=INTEGER},
      #{process.isOxygenDetectorFine,jdbcType=INTEGER}, #{process.isAirRespiratorFine,jdbcType=INTEGER},
      #{process.isHaveWarningSignFine,jdbcType=INTEGER}, #{process.isFireExtinguisherFine,jdbcType=INTEGER},
      #{process.isHaveFirstAidKit,jdbcType=INTEGER}, #{process.bulkStartTime,jdbcType=TIMESTAMP}, #{process.bulkEndTime,jdbcType=TIMESTAMP},
      #{process.bulkGasType,jdbcType=VARCHAR}, #{process.bulkEndToxicGasConcentration,jdbcType=VARCHAR},
      #{process.drugResidueRate,jdbcType=VARCHAR}, #{process.dcsqtinfoId,jdbcType=VARCHAR}, #{process.taskState,jdbcType=INTEGER},
      #{process.taskEndTime,jdbcType=TIMESTAMP}, #{process.creater,jdbcType=INTEGER}, #{process.createTime,jdbcType=TIMESTAMP},
      #{process.updateTime,jdbcType=TIMESTAMP}, #{process.orgId,jdbcType=INTEGER}, #{process.deleteState,jdbcType=VARCHAR},
      #{process.dataSource,jdbcType=VARCHAR})
    </foreach>
  </insert>
</mapper>