feat: 优化景区素材
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<?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.central.order.mapper.TourismFileMapper">
|
||||
@@ -12,4 +12,30 @@
|
||||
<select id="getByTourismId" resultMap="TourismFileResultMap">
|
||||
SELECT * FROM tourisms_files WHERE tourism_id = #{tourismId}
|
||||
</select>
|
||||
|
||||
<select id="findByTourismIds" resultType="com.central.order.model.TourismFile">
|
||||
SELECT *
|
||||
FROM tourisms_files
|
||||
<where>
|
||||
<if test="tourismIds != null and tourismIds.size > 0">
|
||||
tourism_id IN
|
||||
<foreach collection="tourismIds" item="id" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="type != null">
|
||||
AND type = #{type}
|
||||
</if>
|
||||
<if test="status != null">
|
||||
AND status = #{status}
|
||||
</if>
|
||||
<if test="description != null and description != ''">
|
||||
AND description LIKE CONCAT('%', #{description}, '%')
|
||||
</if>
|
||||
<!-- 仅查询未删除数据 -->
|
||||
AND (is_del = 0 OR is_del IS NULL)
|
||||
</where>
|
||||
ORDER BY id DESC
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user