yangys
2025-11-18 8e944cfabb253fc2556588e308e282586043f7b0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?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.qianwen.smartman.modules.smis.mapper.CollectTemplateMapper">
 
    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.qianwen.smartman.modules.smis.entity.CollectTemplate">
        <result column="id" property="id"/>
        <result column="tenant_id" property="tenantId"/>
        
        <result column="type" property="type"/>
        <result column="dp_config" property="dpConfig"/>
    </resultMap>
 
    <select id="selectPage" resultMap="BaseResultMap">
        select * from collect_template where is_deleted=0
       
        <if test="template.name!=null and template.name != ''">
            and (name like CONCAT(#{template.name},'%') OR name like CONCAT(#{template.name},'%'))
        </if>
        <if test="template.type!=null and template.type != ''">
            and type = #{user.type}
        </if>
       
        ORDER BY id
    </select>
 
 
</mapper>