cl
2024-01-19 e0fac38b26845f25de479783e0c76cf12a5311e0
提交 | 用户 | 时间
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.qc.badReasonConf.mapper.BadReasonConfMapper">
4
5     <!-- 通用查询映射结果 -->
6     <resultMap id="BaseResultMap" type="cn.stylefeng.guns.modular.qc.badReasonConf.entity.BadReasonConf">
7         <id column="id" property="id" />
8         <result column="workshop_code" property="workshopCode" />
9         <result column="production_line" property="productionLine" />
10         <result column="location_code" property="locationCode" />
11         <result column="equipment_no" property="equipmentNo" />
12         <result column="type_code" property="typeCode" />
13         <result column="type_name" property="typeName" />
14         <result column="bad_code" property="badCode" />
15         <result column="bad_desc" property="badDesc" />
16         <result column="status" property="status" />
17         <result column="create_user" property="createUser" />
18         <result column="create_time" property="createTime" />
19         <result column="update_user" property="updateUser" />
20         <result column="update_time" property="updateTime" />
21     </resultMap>
22
23     <!-- 通用查询结果列 -->
24     <sql id="Base_Column_List">
25         id AS "id", workshop_code AS "workshopCode", production_line AS "productionLine", location_code AS "locationCode", equipment_no AS "equipmentNo", type_code AS "typeCode", type_name AS "typeName", bad_code AS "badCode", bad_desc AS "badDesc", status AS "status", create_user AS "createUser", create_time AS "createTime", update_user AS "updateUser", update_time AS "updateTime"
26     </sql>
27
28
29     <select id="customList" resultType="cn.stylefeng.guns.modular.qc.badReasonConf.model.result.BadReasonConfResult" parameterType="cn.stylefeng.guns.modular.qc.badReasonConf.model.params.BadReasonConfParam">
30         select
31         <include refid="Base_Column_List"/>
32         from qc_bad_reason_conf where 1 = 1
33     </select>
34
35     <select id="customMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.qc.badReasonConf.model.params.BadReasonConfParam">
36         select
37         <include refid="Base_Column_List"/>
38         from qc_bad_reason_conf where 1 = 1
39     </select>
40
41     <select id="customPageList" resultType="cn.stylefeng.guns.modular.qc.badReasonConf.model.result.BadReasonConfResult" parameterType="cn.stylefeng.guns.modular.qc.badReasonConf.model.params.BadReasonConfParam">
42         select
43         <include refid="Base_Column_List"/>
44         from qc_bad_reason_conf where 1 = 1
45         <if test="paramCondition.workshopCode != null and paramCondition.workshopCode != ''">
46             and workshopCode like CONCAT('%',#{paramCondition.workshopCode},'%')
47         </if>
48         <if test="paramCondition.productionLine != null and paramCondition.productionLine != ''">
49             and production_line like CONCAT('%',#{paramCondition.productionLine},'%')
50         </if>
51         <if test="paramCondition.equipmentNo != null and paramCondition.equipmentNo != ''">
52             and equipment_no like CONCAT('%',#{paramCondition.equipmentNo},'%')
53         </if>
54         <if test="paramCondition.locationCode != null and paramCondition.locationCode != ''">
55             and location_code like CONCAT('%',#{paramCondition.locationCode},'%')
56         </if>
57     </select>
58
59     <select id="customPageMapList" resultType="map" parameterType="cn.stylefeng.guns.modular.qc.badReasonConf.model.params.BadReasonConfParam">
60         select
61         <include refid="Base_Column_List"/>
62         from qc_bad_reason_conf where 1 = 1
63     </select>
64
65 </mapper>