|
@@ -0,0 +1,116 @@
|
|
|
|
+<?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.warehouseBusiness.mapper.TWarehouseWarehousecheckitemsMapper">
|
|
|
|
+ <resultMap type="TWarehouseWarehousecheckitems" id="TWarehouseWarehousecheckitemsResult">
|
|
|
|
+ <result property="fId" column="f_id" />
|
|
|
|
+ <result property="fPid" column="f_pid" />
|
|
|
|
+ <result property="fWarehouseid" column="f_warehouseid" />
|
|
|
|
+ <result property="fWarehousename" column="f_warehousename" />
|
|
|
|
+ <result property="inspectionPhotos" column="inspection_photos" />
|
|
|
|
+ <result property="plannedDate" column="planned_date" />
|
|
|
|
+ <result property="inspectionDate" column="inspection_date" />
|
|
|
|
+ <result property="inspector" column="inspector" />
|
|
|
|
+ <result property="inspectionRemark" column="inspection_remark" />
|
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
|
+ <result property="createTime" column="create_time" />
|
|
|
|
+ <result property="updateBy" column="update_by" />
|
|
|
|
+ <result property="updateTime" column="update_time" />
|
|
|
|
+ <result property="delFlag" column="del_flag" />
|
|
|
|
+ <result property="remark" column="remark" />
|
|
|
|
+ </resultMap>
|
|
|
|
+
|
|
|
|
+ <sql id="selectTWarehouseWarehousecheckitemsVo">
|
|
|
|
+ select f_id, f_pid, f_warehouseid, f_warehousename, inspection_photos, planned_date, inspection_date, inspector, inspection_remark, create_by, create_time, update_by, update_time, del_flag, remark from t_warehouse_warehousecheckitems
|
|
|
|
+ </sql>
|
|
|
|
+
|
|
|
|
+ <select id="selectTWarehouseWarehousecheckitemsList" parameterType="TWarehouseWarehousecheckitems" resultMap="TWarehouseWarehousecheckitemsResult">
|
|
|
|
+ <include refid="selectTWarehouseWarehousecheckitemsVo"/>
|
|
|
|
+ <where>
|
|
|
|
+ <if test="fPid != null "> and f_pid = #{fPid}</if>
|
|
|
|
+ <if test="fWarehouseid != null and fWarehouseid != ''"> and f_warehouseid = #{fWarehouseid}</if>
|
|
|
|
+ <if test="fWarehousename != null and fWarehousename != ''"> and f_warehousename like concat('%', #{fWarehousename}, '%')</if>
|
|
|
|
+ <if test="inspectionPhotos != null and inspectionPhotos != ''"> and inspection_photos = #{inspectionPhotos}</if>
|
|
|
|
+ <if test="plannedDate != null "> and planned_date = #{plannedDate}</if>
|
|
|
|
+ <if test="inspectionDate != null "> and inspection_date = #{inspectionDate}</if>
|
|
|
|
+ <if test="inspector != null and inspector != ''"> and inspector = #{inspector}</if>
|
|
|
|
+ <if test="inspectionRemark != null and inspectionRemark != ''"> and inspection_remark = #{inspectionRemark}</if>
|
|
|
|
+ </where>
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+ <select id="selectTWarehouseWarehousecheckitemsById" parameterType="Long" resultMap="TWarehouseWarehousecheckitemsResult">
|
|
|
|
+ <include refid="selectTWarehouseWarehousecheckitemsVo"/>
|
|
|
|
+ where f_id = #{fId}
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+ <insert id="insertTWarehouseWarehousecheckitems" parameterType="TWarehouseWarehousecheckitems" useGeneratedKeys="true" keyProperty="fId">
|
|
|
|
+ insert into t_warehouse_warehousecheckitems
|
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
|
+ <if test="fPid != null">f_pid,</if>
|
|
|
|
+ <if test="fWarehouseid != null">f_warehouseid,</if>
|
|
|
|
+ <if test="fWarehousename != null">f_warehousename,</if>
|
|
|
|
+ <if test="inspectionPhotos != null">inspection_photos,</if>
|
|
|
|
+ <if test="plannedDate != null">planned_date,</if>
|
|
|
|
+ <if test="inspectionDate != null">inspection_date,</if>
|
|
|
|
+ <if test="inspector != null">inspector,</if>
|
|
|
|
+ <if test="inspectionRemark != null">inspection_remark,</if>
|
|
|
|
+ <if test="createBy != null">create_by,</if>
|
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
|
+ <if test="updateBy != null">update_by,</if>
|
|
|
|
+ <if test="updateTime != null">update_time,</if>
|
|
|
|
+ <if test="delFlag != null">del_flag,</if>
|
|
|
|
+ <if test="remark != null">remark,</if>
|
|
|
|
+ </trim>
|
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
|
+ <if test="fPid != null">#{fPid},</if>
|
|
|
|
+ <if test="fWarehouseid != null">#{fWarehouseid},</if>
|
|
|
|
+ <if test="fWarehousename != null">#{fWarehousename},</if>
|
|
|
|
+ <if test="inspectionPhotos != null">#{inspectionPhotos},</if>
|
|
|
|
+ <if test="plannedDate != null">#{plannedDate},</if>
|
|
|
|
+ <if test="inspectionDate != null">#{inspectionDate},</if>
|
|
|
|
+ <if test="inspector != null">#{inspector},</if>
|
|
|
|
+ <if test="inspectionRemark != null">#{inspectionRemark},</if>
|
|
|
|
+ <if test="createBy != null">#{createBy},</if>
|
|
|
|
+ <if test="createTime != null">#{createTime},</if>
|
|
|
|
+ <if test="updateBy != null">#{updateBy},</if>
|
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
|
|
+ <if test="delFlag != null">#{delFlag},</if>
|
|
|
|
+ <if test="remark != null">#{remark},</if>
|
|
|
|
+ </trim>
|
|
|
|
+ </insert>
|
|
|
|
+
|
|
|
|
+ <update id="updateTWarehouseWarehousecheckitems" parameterType="TWarehouseWarehousecheckitems">
|
|
|
|
+ update t_warehouse_warehousecheckitems
|
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
|
+ <if test="fPid != null">f_pid = #{fPid},</if>
|
|
|
|
+ <if test="fWarehouseid != null">f_warehouseid = #{fWarehouseid},</if>
|
|
|
|
+ <if test="fWarehousename != null">f_warehousename = #{fWarehousename},</if>
|
|
|
|
+ <if test="inspectionPhotos != null">inspection_photos = #{inspectionPhotos},</if>
|
|
|
|
+ <if test="plannedDate != null">planned_date = #{plannedDate},</if>
|
|
|
|
+ <if test="inspectionDate != null">inspection_date = #{inspectionDate},</if>
|
|
|
|
+ <if test="inspector != null">inspector = #{inspector},</if>
|
|
|
|
+ <if test="inspectionRemark != null">inspection_remark = #{inspectionRemark},</if>
|
|
|
|
+ <if test="createBy != null">create_by = #{createBy},</if>
|
|
|
|
+ <if test="createTime != null">create_time = #{createTime},</if>
|
|
|
|
+ <if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
|
+ <if test="delFlag != null">del_flag = #{delFlag},</if>
|
|
|
|
+ <if test="remark != null">remark = #{remark},</if>
|
|
|
|
+ </trim>
|
|
|
|
+ where f_id = #{fId}
|
|
|
|
+ </update>
|
|
|
|
+
|
|
|
|
+ <delete id="deleteTWarehouseWarehousecheckitemsById" parameterType="Long">
|
|
|
|
+ delete from t_warehouse_warehousecheckitems where f_id = #{fId}
|
|
|
|
+ </delete>
|
|
|
|
+
|
|
|
|
+ <delete id="deleteTWarehouseWarehousecheckitemsByIds" parameterType="String">
|
|
|
|
+ delete from t_warehouse_warehousecheckitems where f_id in
|
|
|
|
+ <foreach item="fId" collection="array" open="(" separator="," close=")">
|
|
|
|
+ #{fId}
|
|
|
|
+ </foreach>
|
|
|
|
+ </delete>
|
|
|
|
+
|
|
|
|
+</mapper>
|