75 lines
3.2 KiB
XML
75 lines
3.2 KiB
XML
<?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.device.mapper.AsPlantIdentifyLogMapper">
|
|
|
|
<resultMap type="AsPlantIdentifyLog" id="AsPlantIdentifyLogResult">
|
|
<result property="id" column="id" />
|
|
<result property="userId" column="user_id" />
|
|
<result property="plantName" column="plant_name" />
|
|
<result property="response" column="response" />
|
|
<result property="msg" column="msg" />
|
|
<result property="createTime" column="create_time" />
|
|
</resultMap>
|
|
|
|
<sql id="selectAsPlantIdentifyLogVo">
|
|
select id, user_id, plant_name, url, response, msg, create_time from as_plant_identify_log
|
|
</sql>
|
|
|
|
<select id="selectAsPlantIdentifyLogList" parameterType="AsPlantIdentifyLog" resultMap="AsPlantIdentifyLogResult">
|
|
<include refid="selectAsPlantIdentifyLogVo"/>
|
|
<where>
|
|
</where>
|
|
</select>
|
|
|
|
<select id="selectAsPlantIdentifyLogById" parameterType="Long" resultMap="AsPlantIdentifyLogResult">
|
|
<include refid="selectAsPlantIdentifyLogVo"/>
|
|
where id = #{id}
|
|
</select>
|
|
|
|
<insert id="insertAsPlantIdentifyLog" parameterType="AsPlantIdentifyLog" useGeneratedKeys="true" keyProperty="id">
|
|
insert into as_plant_identify_log
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="userId != null">user_id,</if>
|
|
<if test="plantName != null">plant_name,</if>
|
|
<if test="url != null">url,</if>
|
|
<if test="response != null">response,</if>
|
|
<if test="msg != null">msg,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="userId != null">#{userId},</if>
|
|
<if test="plantName != null">#{plantName},</if>
|
|
<if test="url != null">#{url},</if>
|
|
<if test="response != null">#{response},</if>
|
|
<if test="msg != null">#{msg},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
</trim>
|
|
</insert>
|
|
|
|
<update id="updateAsPlantIdentifyLog" parameterType="AsPlantIdentifyLog">
|
|
update as_plant_identify_log
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="userId != null">user_id = #{userId},</if>
|
|
<if test="plantName != null">plant_name = #{plantName},</if>
|
|
<if test="url != null">url = #{url},</if>
|
|
<if test="response != null">response = #{response},</if>
|
|
<if test="msg != null">msg = #{msg},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
</trim>
|
|
where id = #{id}
|
|
</update>
|
|
|
|
<delete id="deleteAsPlantIdentifyLogById" parameterType="Long">
|
|
delete from as_plant_identify_log where id = #{id}
|
|
</delete>
|
|
|
|
<delete id="deleteAsPlantIdentifyLogByIds" parameterType="String">
|
|
delete from as_plant_identify_log where id in
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
#{id}
|
|
</foreach>
|
|
</delete>
|
|
</mapper>
|