<?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.ard.system.data.mapper.ArdMapManagementMapper">
|
|
<resultMap type="ArdMapManagement" id="ArdMapManagementResult">
|
<result property="id" column="id" />
|
<result property="mapName" column="map_name" />
|
<result property="mapType" column="map_type" />
|
<result property="fileName" column="file_name" />
|
<result property="releaseStatus" column="release_status" />
|
<result property="defaultLoading" column="default_loading" />
|
<result property="mapPath" column="map_path" />
|
</resultMap>
|
|
<sql id="selectArdMapManagementVo">
|
select id,
|
map_name,
|
map_type,
|
file_name,
|
release_status,
|
default_loading,
|
map_path
|
from ard_map_management
|
</sql>
|
|
<select id="selectArdMapManagementList" parameterType="ArdMapManagement" resultMap="ArdMapManagementResult">
|
<include refid="selectArdMapManagementVo"/>
|
<where>
|
<if test="mapName != null and mapName != ''"> and map_name like concat('%', #{mapName}, '%')</if>
|
<if test="mapType != null and mapType != ''"> and map_type = #{mapType}</if>
|
<if test="fileName != null and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if>
|
<if test="releaseStatus != null and releaseStatus != ''"> and release_status = #{releaseStatus}</if>
|
</where>
|
</select>
|
|
<select id="selectArdMapManagementById" parameterType="String" resultMap="ArdMapManagementResult">
|
<include refid="selectArdMapManagementVo"/>
|
where id = #{id}
|
</select>
|
|
<insert id="insertArdMapManagement" parameterType="ArdMapManagement">
|
insert into ard_map_management
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<if test="id != null">id,</if>
|
<if test="mapName != null">map_name,</if>
|
<if test="mapType != null">map_type,</if>
|
<if test="fileName != null">file_name,</if>
|
<if test="releaseStatus != null">release_status,</if>
|
<if test="defaultLoading != null">default_loading,</if>
|
<if test="mapPath != null">map_path,</if>
|
</trim>
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<if test="id != null">#{id},</if>
|
<if test="mapName != null">#{mapName},</if>
|
<if test="mapType != null">#{mapType},</if>
|
<if test="fileName != null">#{fileName},</if>
|
<if test="releaseStatus != null">#{releaseStatus},</if>
|
<if test="defaultLoading != null">#{defaultLoading},</if>
|
<if test="mapPath != null">#{mapPath},</if>
|
</trim>
|
</insert>
|
|
<update id="updateArdMapManagement" parameterType="ArdMapManagement">
|
update ard_map_management
|
<trim prefix="SET" suffixOverrides=",">
|
<if test="mapName != null">map_name = #{mapName},</if>
|
<if test="mapType != null">map_type = #{mapType},</if>
|
<if test="fileName != null">file_name = #{fileName},</if>
|
<if test="releaseStatus != null">release_status = #{releaseStatus},</if>
|
<if test="defaultLoading != null">default_loading = #{defaultLoading},</if>
|
<if test="mapPath != null">map_path = #{mapPath},</if>
|
</trim>
|
where id = #{id}
|
</update>
|
|
<delete id="deleteArdMapManagementById" parameterType="String">
|
delete from ard_map_management where id = #{id}
|
</delete>
|
|
<delete id="deleteArdMapManagementByIds" parameterType="String">
|
delete from ard_map_management where id in
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
#{id}
|
</foreach>
|
</delete>
|
</mapper>
|