<?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.nanometer.smartlab.dao.TempSensorsDao">
|
<resultMap id="BaseResultMap" type="com.nanometer.smartlab.entity.TempSensors">
|
<id property="id" column="id"/>
|
<id column="id" jdbcType="VARCHAR" property="id" />
|
<result column="container_id" jdbcType="VARCHAR" property="containerId" />
|
<result column="warehouse_container_name" jdbcType="VARCHAR" property="warehouseContainerName" />
|
<result column="laboratory_container_name" jdbcType="VARCHAR" property="laboratoryContainerName" />
|
<result column="temp" jdbcType="DOUBLE" property="temp" />
|
<result column="humidity" jdbcType="INTEGER" property="humidity" />
|
<result column="voc1" jdbcType="INTEGER" property="voc1" />
|
<result column="flag" jdbcType="INTEGER" property="flag" />
|
<result column="type" jdbcType="TINYINT" property="type" />
|
<result column="laboratory_name" jdbcType="VARCHAR" property="laboratoryName" />
|
<result column="warehouse_name" jdbcType="VARCHAR" property="warehouseName" />
|
<result column="laboratory_id" jdbcType="VARCHAR" property="laboratoryId" />
|
<result column="warehouse_id" jdbcType="VARCHAR" property="warehouseId" />
|
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
|
</resultMap>
|
|
<insert id="insertWatning" parameterType="com.nanometer.smartlab.entity.TempSensors">
|
insert into sys_container_sensors
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<if test="containerId != null">
|
container_id,
|
</if>
|
<if test="temp != null">
|
temp,
|
</if>
|
<if test="humidity != null">
|
humidity,
|
</if>
|
<if test="voc1 != null">
|
voc1,
|
</if>
|
<if test="flag != null">
|
flag,
|
</if>
|
<if test="type != null">
|
type,
|
</if>
|
<if test="updateTime != null">
|
update_time,
|
</if>
|
</trim>
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<if test="containerId != null">
|
#{containerId,jdbcType=VARCHAR},
|
</if>
|
<if test="temp != null">
|
#{temp,jdbcType=DOUBLE},
|
</if>
|
<if test="humidity != null">
|
#{humidity,jdbcType=INTEGER},
|
</if>
|
<if test="voc1 != null">
|
#{voc1,jdbcType=INTEGER},
|
</if>
|
<if test="flag != null">
|
#{flag,jdbcType=INTEGER},
|
</if>
|
<if test="type != null">
|
#{type,jdbcType=BIT},
|
</if>
|
<if test="updateTime != null">
|
#{updateTime,jdbcType=TIMESTAMP},
|
</if>
|
</trim>
|
</insert>
|
|
|
</mapper>
|