<?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.chaozhanggui.dao.system.dao.TbPlussMercOrderExpressDetailMapper">
  <resultMap id="BaseResultMap" type="com.chaozhanggui.dao.system.entity.TbPlussMercOrderExpressDetail">
    <id column="id" jdbcType="INTEGER" property="id" />
    <result column="orderNo" jdbcType="VARCHAR" property="orderno" />
    <result column="logisticProvider" jdbcType="VARCHAR" property="logisticprovider" />
    <result column="expressNo" jdbcType="VARCHAR" property="expressno" />
    <result column="logistNo" jdbcType="VARCHAR" property="logistno" />
    <result column="city" jdbcType="VARCHAR" property="city" />
    <result column="district" jdbcType="VARCHAR" property="district" />
    <result column="acceptTime" jdbcType="TIMESTAMP" property="accepttime" />
    <result column="remark" jdbcType="VARCHAR" property="remark" />
    <result column="empCode" jdbcType="VARCHAR" property="empcode" />
    <result column="empName" jdbcType="VARCHAR" property="empname" />
    <result column="info" jdbcType="VARCHAR" property="info" />
    <result column="weight" jdbcType="DECIMAL" property="weight" />
    <result column="contactInfo" jdbcType="VARCHAR" property="contactinfo" />
    <result column="questionCause" jdbcType="VARCHAR" property="questioncause" />
    <result column="deliveryName" jdbcType="VARCHAR" property="deliveryname" />
    <result column="orgName" jdbcType="VARCHAR" property="orgname" />
    <result column="orgCode" jdbcType="VARCHAR" property="orgcode" />
    <result column="orgPhone" jdbcType="VARCHAR" property="orgphone" />
    <result column="createTime" jdbcType="TIMESTAMP" property="createtime" />
  </resultMap>
  <sql id="Base_Column_List">
    id, orderNo, logisticProvider, expressNo, logistNo, city, district, acceptTime, remark, 
    empCode, empName, info, weight, contactInfo, questionCause, deliveryName, orgName, 
    orgCode, orgPhone, createTime
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
    select 
    <include refid="Base_Column_List" />
    from tb_pluss_merc_order_express_detail
    where id = #{id,jdbcType=INTEGER}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
    delete from tb_pluss_merc_order_express_detail
    where id = #{id,jdbcType=INTEGER}
  </delete>
  <insert id="insert" parameterType="com.chaozhanggui.dao.system.entity.TbPlussMercOrderExpressDetail">
    insert into tb_pluss_merc_order_express_detail (id, orderNo, logisticProvider, 
      expressNo, logistNo, city, 
      district, acceptTime, remark, 
      empCode, empName, info, 
      weight, contactInfo, questionCause, 
      deliveryName, orgName, orgCode, 
      orgPhone, createTime)
    values (#{id,jdbcType=INTEGER}, #{orderno,jdbcType=VARCHAR}, #{logisticprovider,jdbcType=VARCHAR}, 
      #{expressno,jdbcType=VARCHAR}, #{logistno,jdbcType=VARCHAR}, #{city,jdbcType=VARCHAR}, 
      #{district,jdbcType=VARCHAR}, #{accepttime,jdbcType=TIMESTAMP}, #{remark,jdbcType=VARCHAR}, 
      #{empcode,jdbcType=VARCHAR}, #{empname,jdbcType=VARCHAR}, #{info,jdbcType=VARCHAR}, 
      #{weight,jdbcType=DECIMAL}, #{contactinfo,jdbcType=VARCHAR}, #{questioncause,jdbcType=VARCHAR}, 
      #{deliveryname,jdbcType=VARCHAR}, #{orgname,jdbcType=VARCHAR}, #{orgcode,jdbcType=VARCHAR}, 
      #{orgphone,jdbcType=VARCHAR}, #{createtime,jdbcType=TIMESTAMP})
  </insert>
  <insert id="insertSelective" parameterType="com.chaozhanggui.dao.system.entity.TbPlussMercOrderExpressDetail">
    insert into tb_pluss_merc_order_express_detail
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">
        id,
      </if>
      <if test="orderno != null">
        orderNo,
      </if>
      <if test="logisticprovider != null">
        logisticProvider,
      </if>
      <if test="expressno != null">
        expressNo,
      </if>
      <if test="logistno != null">
        logistNo,
      </if>
      <if test="city != null">
        city,
      </if>
      <if test="district != null">
        district,
      </if>
      <if test="accepttime != null">
        acceptTime,
      </if>
      <if test="remark != null">
        remark,
      </if>
      <if test="empcode != null">
        empCode,
      </if>
      <if test="empname != null">
        empName,
      </if>
      <if test="info != null">
        info,
      </if>
      <if test="weight != null">
        weight,
      </if>
      <if test="contactinfo != null">
        contactInfo,
      </if>
      <if test="questioncause != null">
        questionCause,
      </if>
      <if test="deliveryname != null">
        deliveryName,
      </if>
      <if test="orgname != null">
        orgName,
      </if>
      <if test="orgcode != null">
        orgCode,
      </if>
      <if test="orgphone != null">
        orgPhone,
      </if>
      <if test="createtime != null">
        createTime,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="id != null">
        #{id,jdbcType=INTEGER},
      </if>
      <if test="orderno != null">
        #{orderno,jdbcType=VARCHAR},
      </if>
      <if test="logisticprovider != null">
        #{logisticprovider,jdbcType=VARCHAR},
      </if>
      <if test="expressno != null">
        #{expressno,jdbcType=VARCHAR},
      </if>
      <if test="logistno != null">
        #{logistno,jdbcType=VARCHAR},
      </if>
      <if test="city != null">
        #{city,jdbcType=VARCHAR},
      </if>
      <if test="district != null">
        #{district,jdbcType=VARCHAR},
      </if>
      <if test="accepttime != null">
        #{accepttime,jdbcType=TIMESTAMP},
      </if>
      <if test="remark != null">
        #{remark,jdbcType=VARCHAR},
      </if>
      <if test="empcode != null">
        #{empcode,jdbcType=VARCHAR},
      </if>
      <if test="empname != null">
        #{empname,jdbcType=VARCHAR},
      </if>
      <if test="info != null">
        #{info,jdbcType=VARCHAR},
      </if>
      <if test="weight != null">
        #{weight,jdbcType=DECIMAL},
      </if>
      <if test="contactinfo != null">
        #{contactinfo,jdbcType=VARCHAR},
      </if>
      <if test="questioncause != null">
        #{questioncause,jdbcType=VARCHAR},
      </if>
      <if test="deliveryname != null">
        #{deliveryname,jdbcType=VARCHAR},
      </if>
      <if test="orgname != null">
        #{orgname,jdbcType=VARCHAR},
      </if>
      <if test="orgcode != null">
        #{orgcode,jdbcType=VARCHAR},
      </if>
      <if test="orgphone != null">
        #{orgphone,jdbcType=VARCHAR},
      </if>
      <if test="createtime != null">
        #{createtime,jdbcType=TIMESTAMP},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="com.chaozhanggui.dao.system.entity.TbPlussMercOrderExpressDetail">
    update tb_pluss_merc_order_express_detail
    <set>
      <if test="orderno != null">
        orderNo = #{orderno,jdbcType=VARCHAR},
      </if>
      <if test="logisticprovider != null">
        logisticProvider = #{logisticprovider,jdbcType=VARCHAR},
      </if>
      <if test="expressno != null">
        expressNo = #{expressno,jdbcType=VARCHAR},
      </if>
      <if test="logistno != null">
        logistNo = #{logistno,jdbcType=VARCHAR},
      </if>
      <if test="city != null">
        city = #{city,jdbcType=VARCHAR},
      </if>
      <if test="district != null">
        district = #{district,jdbcType=VARCHAR},
      </if>
      <if test="accepttime != null">
        acceptTime = #{accepttime,jdbcType=TIMESTAMP},
      </if>
      <if test="remark != null">
        remark = #{remark,jdbcType=VARCHAR},
      </if>
      <if test="empcode != null">
        empCode = #{empcode,jdbcType=VARCHAR},
      </if>
      <if test="empname != null">
        empName = #{empname,jdbcType=VARCHAR},
      </if>
      <if test="info != null">
        info = #{info,jdbcType=VARCHAR},
      </if>
      <if test="weight != null">
        weight = #{weight,jdbcType=DECIMAL},
      </if>
      <if test="contactinfo != null">
        contactInfo = #{contactinfo,jdbcType=VARCHAR},
      </if>
      <if test="questioncause != null">
        questionCause = #{questioncause,jdbcType=VARCHAR},
      </if>
      <if test="deliveryname != null">
        deliveryName = #{deliveryname,jdbcType=VARCHAR},
      </if>
      <if test="orgname != null">
        orgName = #{orgname,jdbcType=VARCHAR},
      </if>
      <if test="orgcode != null">
        orgCode = #{orgcode,jdbcType=VARCHAR},
      </if>
      <if test="orgphone != null">
        orgPhone = #{orgphone,jdbcType=VARCHAR},
      </if>
      <if test="createtime != null">
        createTime = #{createtime,jdbcType=TIMESTAMP},
      </if>
    </set>
    where id = #{id,jdbcType=INTEGER}
  </update>
  <update id="updateByPrimaryKey" parameterType="com.chaozhanggui.dao.system.entity.TbPlussMercOrderExpressDetail">
    update tb_pluss_merc_order_express_detail
    set orderNo = #{orderno,jdbcType=VARCHAR},
      logisticProvider = #{logisticprovider,jdbcType=VARCHAR},
      expressNo = #{expressno,jdbcType=VARCHAR},
      logistNo = #{logistno,jdbcType=VARCHAR},
      city = #{city,jdbcType=VARCHAR},
      district = #{district,jdbcType=VARCHAR},
      acceptTime = #{accepttime,jdbcType=TIMESTAMP},
      remark = #{remark,jdbcType=VARCHAR},
      empCode = #{empcode,jdbcType=VARCHAR},
      empName = #{empname,jdbcType=VARCHAR},
      info = #{info,jdbcType=VARCHAR},
      weight = #{weight,jdbcType=DECIMAL},
      contactInfo = #{contactinfo,jdbcType=VARCHAR},
      questionCause = #{questioncause,jdbcType=VARCHAR},
      deliveryName = #{deliveryname,jdbcType=VARCHAR},
      orgName = #{orgname,jdbcType=VARCHAR},
      orgCode = #{orgcode,jdbcType=VARCHAR},
      orgPhone = #{orgphone,jdbcType=VARCHAR},
      createTime = #{createtime,jdbcType=TIMESTAMP}
    where id = #{id,jdbcType=INTEGER}
  </update>
</mapper>