| | |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ard.tianyu.mapper.UavBoxMapper"> |
| | | |
| | | <resultMap type="UavBox" id="UavBoxResult"> |
| | | <resultMap type="UavBoxEntity" id="UavBoxResult"> |
| | | <result property="id" column="id" /> |
| | | <result property="boxSn" column="box_sn" /> |
| | | <result property="boxName" column="box_name" /> |
| | |
| | | select id, box_sn, box_name, box_version, onLine, last_task_id, user_id, dept_id, create_by, create_time, update_by, update_time, remark from uav_box |
| | | </sql> |
| | | |
| | | <select id="selectUavBoxList" parameterType="UavBox" resultMap="UavBoxResult"> |
| | | <select id="selectUavBoxList" parameterType="UavBoxEntity" resultMap="UavBoxResult"> |
| | | <include refid="selectUavBoxVo"/> |
| | | <where> |
| | | <if test="boxSn != null and boxSn != ''"> and box_sn = #{boxSn}</if> |
| | |
| | | where id = #{id} |
| | | </select> |
| | | |
| | | <insert id="insertUavBox" parameterType="UavBox"> |
| | | <insert id="insertUavBox" parameterType="UavBoxEntity"> |
| | | insert into uav_box |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | |
| | | </trim> |
| | | </insert> |
| | | |
| | | <update id="updateUavBox" parameterType="UavBox"> |
| | | <update id="updateUavBox" parameterType="UavBoxEntity"> |
| | | update uav_box |
| | | <trim prefix="SET" suffixOverrides=","> |
| | | <if test="boxSn != null">box_sn = #{boxSn},</if> |