long
2023-09-02 e379948bb83ebcc9ce0c467a7b970f74bc00e9a1
提交 | 用户 | 时间
71e81e 1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3 <mapper namespace="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.mapper.EquipmentMaintainContentTaskMapper">
4
5     <!-- 通用查询映射结果 -->
6     <resultMap id="BaseResultMap" type="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.entity.EquipmentMaintainContentTask">
7         <id column="id" property="id" />
8         <result column="maintain_content_code" property="maintainContentCode" />
9         <result column="maintain_content_name" property="maintainContentName" />
10         <result column="maintain_content_type" property="maintainContentType" />
11         <result column="maintain_content" property="maintainContent" />
12         <result column="spare_field_1" property="spareField1" />
13         <result column="spare_field_2" property="spareField2" />
14         <result column="maintain_result" property="maintainResult" />
15         <result column="maintain_record" property="maintainRecord" />
16         <result column="remarks" property="remarks" />
17         <result column="task_no" property="taskNo" />
18     </resultMap>
19
20     <!-- 通用查询结果列 -->
21     <sql id="Base_Column_List">
22         id AS "id", maintain_content_code AS "maintainContentCode", maintain_content_name AS "maintainContentName", maintain_content_type AS "maintainContentType", maintain_content AS "maintainContent", spare_field_1 AS "spareField1", spare_field_2 AS "spareField2", maintain_result AS "maintainResult", maintain_record AS "maintainRecord", remarks AS "remarks", task_no AS "taskNo"
23     </sql>
24
25
26     <select id="customList" resultType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.result.EquipmentMaintainContentTaskResult" parameterType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.params.EquipmentMaintainContentTaskParam">
27         select
28         <include refid="Base_Column_List"/>
29         from em_equipment_maintain_content_task where 1 = 1
30     </select>
31
32     <select id="customMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.params.EquipmentMaintainContentTaskParam">
33         select
34         <include refid="Base_Column_List"/>
35         from em_equipment_maintain_content_task where 1 = 1
36     </select>
37
38     <select id="customPageList" resultType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.result.EquipmentMaintainContentTaskResult" parameterType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.params.EquipmentMaintainContentTaskParam">
39         select
40         <include refid="Base_Column_List"/>
41         from em_equipment_maintain_content_task where 1 = 1
42         <if test="paramCondition.maintainContentCode != null and paramCondition.maintainContentCode != ''">
43             and maintain_content_code like CONCAT('%',#{paramCondition.maintainContentCode},'%')
44         </if>
45         <if test="paramCondition.maintainContentName != null and paramCondition.maintainContentName != ''">
46             and maintain_content_name like CONCAT('%',#{paramCondition.maintainContentName},'%')
47         </if>
48         <if test="paramCondition.taskNo != null and paramCondition.taskNo != ''">
49             and task_no like CONCAT('%',#{paramCondition.taskNo},'%')
50         </if>
51     </select>
52
53     <select id="customPageMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.em.equipmentMaintainContentTask.model.params.EquipmentMaintainContentTaskParam">
54         select
55         <include refid="Base_Column_List"/>
56         from em_equipment_maintain_content_task where 1 = 1
57     </select>
58
59 </mapper>