liurunyu
2024-07-17 4bd0c2c252df008b98d3e9c7dac708ff642c90d1
pipIrr-platform/pipIrr-global/src/main/resources/mapper/RmCommandHistoryMapper.xml
@@ -15,35 +15,37 @@
    <result column="operator" jdbcType="BIGINT" property="operator" />
    <result column="result" jdbcType="TINYINT" property="result" />
    <result column="result_time" jdbcType="TIMESTAMP" property="resultTime" />
    <result column="result_text" property="resultText" jdbcType="JAVA_OBJECT" typeHandler="com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler" />
    <result column="result_text" jdbcType="LONGVARCHAR" property="resultText" />
  </resultMap>
  <sql id="Base_Column_List">
    <!--@mbg.generated-->
    com_id, command_code, command_name, intake_id, rtu_addr, protocol, param, send_time, `operator`,
    `result`, result_time, result_text
    com_id, command_code, command_name, intake_id, rtu_addr, protocol, param, send_time,
    `operator`, `result`, result_time, result_text
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    <!--@mbg.generated-->
    select 
    <include refid="Base_Column_List" />
    from rm_command_history
    where com_id = #{id,jdbcType=BIGINT}
    where com_id = #{comId,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
    <!--@mbg.generated-->
    delete from rm_command_history
    where com_id = #{id,jdbcType=BIGINT}
    where com_id = #{comId,jdbcType=BIGINT}
  </delete>
  <insert id="insert" parameterType="com.dy.pipIrrGlobal.pojoRm.RmCommandHistory">
    <!--@mbg.generated-->
    insert into rm_command_history (com_id, command_code, command_name,
      intake_id, rtu_addr, protocol, param,
      send_time, `operator`, `result`,
      result_time, result_text)
    values (#{comId,jdbcType=BIGINT}, #{commandCode,jdbcType=VARCHAR}, #{commandName,jdbcType=VARCHAR}, #{intakeId,jdbcType=BIGINT},
      #{rtuAddr,jdbcType=VARCHAR}, #{protocol,jdbcType=VARCHAR}, #{param,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
      #{sendTime,jdbcType=TIMESTAMP}, #{operator,jdbcType=BIGINT}, #{result,jdbcType=TINYINT},
      #{resultTime,jdbcType=TIMESTAMP}, #{resultText,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler})
      intake_id, rtu_addr, protocol,
      param, send_time, `operator`,
      `result`, result_time, result_text
      )
    values (#{comId,jdbcType=BIGINT}, #{commandCode,jdbcType=VARCHAR}, #{commandName,jdbcType=VARCHAR},
      #{intakeId,jdbcType=BIGINT}, #{rtuAddr,jdbcType=VARCHAR}, #{protocol,jdbcType=VARCHAR},
      #{param,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler}, #{sendTime,jdbcType=TIMESTAMP}, #{operator,jdbcType=BIGINT},
      #{result,jdbcType=TINYINT}, #{resultTime,jdbcType=TIMESTAMP}, #{resultText,jdbcType=LONGVARCHAR}
      )
  </insert>
  <insert id="insertSelective" parameterType="com.dy.pipIrrGlobal.pojoRm.RmCommandHistory">
    <!--@mbg.generated-->
@@ -121,7 +123,7 @@
        #{resultTime,jdbcType=TIMESTAMP},
      </if>
      <if test="resultText != null">
        #{resultText,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
        #{resultText,jdbcType=LONGVARCHAR},
      </if>
    </trim>
  </insert>
@@ -160,7 +162,7 @@
        result_time = #{resultTime,jdbcType=TIMESTAMP},
      </if>
      <if test="resultText != null">
        result_text = #{resultText,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler},
        result_text = #{resultText,jdbcType=LONGVARCHAR},
      </if>
    </set>
    where com_id = #{comId,jdbcType=BIGINT}
@@ -178,7 +180,7 @@
      `operator` = #{operator,jdbcType=BIGINT},
      `result` = #{result,jdbcType=TINYINT},
      result_time = #{resultTime,jdbcType=TIMESTAMP},
      result_text = #{resultText,jdbcType= JAVA_OBJECT, typeHandler=com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler}
      result_text = #{resultText,jdbcType=LONGVARCHAR}
    where com_id = #{comId,jdbcType=BIGINT}
  </update>
@@ -304,5 +306,4 @@
      </if>
    </trim>
  </select>
</mapper>