cl
2024-07-02 8c5c9cfbe2dfa4b40636ec974feaf48ace0d271f
提交 | 用户 | 时间
0ca254 1 <?xml version="1.0" encoding="UTF-8" ?>
A 2 <!DOCTYPE mapper
3 PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4 "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5 <mapper namespace="com.jcdm.main.da.collectionParamConf.mapper.DaCollectionParamConfMapper">
6     
7     <resultMap type="DaCollectionParamConf" id="DaCollectionParamConfResult">
8         <result property="id"    column="id"    />
9         <result property="processesCode"    column="processes_code"    />
10         <result property="parameterSetCode"    column="parameter_set_code"    />
11         <result property="parameterSetName"    column="parameter_set_name"    />
12         <result property="collectParameterId"    column="collect_parameter_id"    />
13         <result property="collectParameterName"    column="collect_parameter_name"    />
14         <result property="contrastParameterFlag"    column="contrast_parameter_flag"    />
15         <result property="collectParameterType"    column="collect_parameter_type"    />
16         <result property="collectParameterUnit"    column="collect_parameter_unit"    />
8c5c9c 17         <result property="descriptives"    column="descriptives"    />
0ca254 18         <result property="paramUpper"    column="param_upper"    />
A 19         <result property="paramLower"    column="param_lower"    />
20         <result property="paramCentral"    column="param_Central"    />
21         <result property="productCode"    column="product_code"    />
22         <result property="gatherAddress"    column="gather_address"    />
23         <result property="gatherSequence"    column="gather_sequence"    />
24         <result property="remarks"    column="remarks"    />
25         <result property="createUser"    column="create_user"    />
26         <result property="createTime"    column="create_time"    />
27         <result property="updateUser"    column="update_user"    />
28         <result property="updateTime"    column="update_time"    />
29         <result property="spareField1"    column="spare_field1"    />
30         <result property="spareField2"    column="spare_field2"    />
31         <result property="spareField3"    column="spare_field3"    />
32         <result property="spareField4"    column="spare_field4"    />
33         <result property="processesName"    column="processes_name"    />
34         <result property="device"    column="device"    />
35         <result property="project"    column="project"    />
36         <result property="accuracy"    column="accuracy"    />
37         <result property="arrayLength"    column="array_length"    />
38         <result property="acquisitionFrequency"    column="acquisition_frequency"    />
39         <result property="demandDepartment"    column="demand_department"    />
40         <result property="whetherToCollect"    column="whether_to_collect"    />
41         <result property="defaultValue"    column="default_value"    />
42         <result property="productModel"    column="product_model"    />
109e2f 43         <result property="keyNum"    column="key_num"    />
C 44         <result property="itemType"    column="item_type"    />
0ca254 45
A 46     </resultMap>
47
48     <sql id="selectDaCollectionParamConfVo">
8c5c9c 49         select id, key_num,item_type,processes_code, product_model, parameter_set_code, parameter_set_name, collect_parameter_id, collect_parameter_name, contrast_parameter_flag, collect_parameter_type, collect_parameter_unit, descriptives, param_upper, param_lower, param_Central, product_code, gather_address, gather_sequence, remarks, create_user, create_time, update_user, update_time, spare_field1, spare_field2, spare_field3, spare_field4, processes_name, device, project, accuracy, array_length, acquisition_frequency, demand_department, whether_to_collect, default_value from da_collection_param_conf
0ca254 50     </sql>
A 51
52     <select id="selectDaCollectionParamConfList" parameterType="DaCollectionParamConf" resultMap="DaCollectionParamConfResult">
53         <include refid="selectDaCollectionParamConfVo"/>
54         <where>  
55             <if test="processesCode != null  and processesCode != ''"> and processes_code like concat('%', #{processesCode}, '%')</if>
56             <if test="parameterSetCode != null  and parameterSetCode != ''"> and parameter_set_code like concat('%', #{parameterSetCode}, '%')</if>
57             <if test="parameterSetName != null  and parameterSetName != ''"> and parameter_set_name like concat('%', #{parameterSetName}, '%')</if>
58             <if test="collectParameterId != null  and collectParameterId != ''"> and collect_parameter_id like concat('%', #{collectParameterId}, '%')</if>
59             <if test="collectParameterName != null  and collectParameterName != ''"> and collect_parameter_name like concat('%', #{collectParameterName}, '%')</if>
60             <if test="contrastParameterFlag != null  and contrastParameterFlag != ''"> and contrast_parameter_flag like concat('%', #{contrastParameterFlag}, '%')</if>
61             <if test="collectParameterType != null  and collectParameterType != ''"> and collect_parameter_type like concat('%', #{collectParameterType}, '%')</if>
62             <if test="productCode != null  and productCode != ''"> and product_code like concat('%', #{productCode}, '%')</if>
63             <if test="gatherAddress != null  and gatherAddress != ''"> and gather_address like concat('%', #{gatherAddress}, '%')</if>
64
65         </where>
66     </select>
67     
68     <select id="selectDaCollectionParamConfById" parameterType="Long" resultMap="DaCollectionParamConfResult">
69         <include refid="selectDaCollectionParamConfVo"/>
70         where id = #{id}
71     </select>
72         
73     <insert id="insertDaCollectionParamConf" parameterType="DaCollectionParamConf">
74         insert into da_collection_param_conf
75         <trim prefix="(" suffix=")" suffixOverrides=",">
76             <if test="id != null">id,</if>
77             <if test="processesCode != null">processes_code,</if>
78             <if test="parameterSetCode != null">parameter_set_code,</if>
79             <if test="parameterSetName != null">parameter_set_name,</if>
80             <if test="collectParameterId != null">collect_parameter_id,</if>
81             <if test="collectParameterName != null">collect_parameter_name,</if>
82             <if test="contrastParameterFlag != null">contrast_parameter_flag,</if>
83             <if test="collectParameterType != null">collect_parameter_type,</if>
84             <if test="collectParameterUnit != null">collect_parameter_unit,</if>
8c5c9c 85             <if test="descriptives != null">descriptives,</if>
0ca254 86             <if test="paramUpper != null">param_upper,</if>
A 87             <if test="paramLower != null">param_lower,</if>
88             <if test="paramCentral != null">param_Central,</if>
89             <if test="productCode != null">product_code,</if>
90             <if test="gatherAddress != null">gather_address,</if>
91             <if test="gatherSequence != null">gather_sequence,</if>
92             <if test="remarks != null">remarks,</if>
93             <if test="createUser != null">create_user,</if>
94             <if test="createTime != null">create_time,</if>
95             <if test="updateUser != null">update_user,</if>
96             <if test="updateTime != null">update_time,</if>
97             <if test="spareField1 != null">spare_field1,</if>
98             <if test="spareField2 != null">spare_field2,</if>
99             <if test="spareField3 != null">spare_field3,</if>
100             <if test="spareField4 != null">spare_field4,</if>
101             <if test="processesName != null">processes_name,</if>
102             <if test="device != null">device,</if>
103             <if test="project != null">project,</if>
104             <if test="accuracy != null">accuracy,</if>
105             <if test="arrayLength != null">array_length,</if>
106             <if test="acquisitionFrequency != null">acquisition_frequency,</if>
107             <if test="demandDepartment != null">demand_department,</if>
108             <if test="whetherToCollect != null">whether_to_collect,</if>
109             <if test="defaultValue != null">default_value,</if>
110             <if test="productModel != null">product_model,</if>
111
112         </trim>
113         <trim prefix="values (" suffix=")" suffixOverrides=",">
114             <if test="id != null">#{id},</if>
115             <if test="processesCode != null">#{processesCode},</if>
116             <if test="parameterSetCode != null">#{parameterSetCode},</if>
117             <if test="parameterSetName != null">#{parameterSetName},</if>
118             <if test="collectParameterId != null">#{collectParameterId},</if>
119             <if test="collectParameterName != null">#{collectParameterName},</if>
120             <if test="contrastParameterFlag != null">#{contrastParameterFlag},</if>
121             <if test="collectParameterType != null">#{collectParameterType},</if>
122             <if test="collectParameterUnit != null">#{collectParameterUnit},</if>
8c5c9c 123             <if test="descriptives != null">#{descriptives},</if>
0ca254 124             <if test="paramUpper != null">#{paramUpper},</if>
A 125             <if test="paramLower != null">#{paramLower},</if>
126             <if test="paramCentral != null">#{paramCentral},</if>
127             <if test="productCode != null">#{productCode},</if>
128             <if test="gatherAddress != null">#{gatherAddress},</if>
129             <if test="gatherSequence != null">#{gatherSequence},</if>
130             <if test="remarks != null">#{remarks},</if>
131             <if test="createUser != null">#{createUser},</if>
132             <if test="createTime != null">#{createTime},</if>
133             <if test="updateUser != null">#{updateUser},</if>
134             <if test="updateTime != null">#{updateTime},</if>
135             <if test="spareField1 != null">#{spareField1},</if>
136             <if test="spareField2 != null">#{spareField2},</if>
137             <if test="spareField3 != null">#{spareField3},</if>
138             <if test="spareField4 != null">#{spareField4},</if>
139             <if test="processesName != null">#{processesName},</if>
140             <if test="device != null">#{device},</if>
141             <if test="project != null">#{project},</if>
142             <if test="accuracy != null">#{accuracy},</if>
143             <if test="arrayLength != null">#{arrayLength},</if>
144             <if test="acquisitionFrequency != null">#{acquisitionFrequency},</if>
145             <if test="demandDepartment != null">#{demandDepartment},</if>
146             <if test="whetherToCollect != null">#{whetherToCollect},</if>
147             <if test="defaultValue != null">#{defaultValue},</if>
148             <if test="productModel != null">#{productModel},</if>
149
150         </trim>
151     </insert>
152
153     <update id="updateDaCollectionParamConf" parameterType="DaCollectionParamConf">
154         update da_collection_param_conf
155         <trim prefix="SET" suffixOverrides=",">
156             <if test="processesCode != null">processes_code = #{processesCode},</if>
157             <if test="parameterSetCode != null">parameter_set_code = #{parameterSetCode},</if>
158             <if test="parameterSetName != null">parameter_set_name = #{parameterSetName},</if>
159             <if test="collectParameterId != null">collect_parameter_id = #{collectParameterId},</if>
160             <if test="collectParameterName != null">collect_parameter_name = #{collectParameterName},</if>
161             <if test="contrastParameterFlag != null">contrast_parameter_flag = #{contrastParameterFlag},</if>
162             <if test="collectParameterType != null">collect_parameter_type = #{collectParameterType},</if>
163             <if test="collectParameterUnit != null">collect_parameter_unit = #{collectParameterUnit},</if>
8c5c9c 164             <if test="descriptives != null">descriptives = #{descriptives},</if>
0ca254 165             <if test="paramUpper != null">param_upper = #{paramUpper},</if>
A 166             <if test="paramLower != null">param_lower = #{paramLower},</if>
167             <if test="paramCentral != null">param_Central = #{paramCentral},</if>
168             <if test="productCode != null">product_code = #{productCode},</if>
169             <if test="gatherAddress != null">gather_address = #{gatherAddress},</if>
170             <if test="gatherSequence != null">gather_sequence = #{gatherSequence},</if>
171             <if test="remarks != null">remarks = #{remarks},</if>
172             <if test="createUser != null">create_user = #{createUser},</if>
173             <if test="createTime != null">create_time = #{createTime},</if>
174             <if test="updateUser != null">update_user = #{updateUser},</if>
175             <if test="updateTime != null">update_time = #{updateTime},</if>
176             <if test="spareField1 != null">spare_field1 = #{spareField1},</if>
177             <if test="spareField2 != null">spare_field2 = #{spareField2},</if>
178             <if test="spareField3 != null">spare_field3 = #{spareField3},</if>
179             <if test="spareField4 != null">spare_field4 = #{spareField4},</if>
180             <if test="processesName != null">processes_name = #{processesName},</if>
181             <if test="device != null">device = #{device},</if>
182             <if test="project != null">project = #{project},</if>
183             <if test="accuracy != null">accuracy = #{accuracy},</if>
184             <if test="arrayLength != null">array_length = #{arrayLength},</if>
185             <if test="acquisitionFrequency != null">acquisition_frequency = #{acquisitionFrequency},</if>
186             <if test="demandDepartment != null">demand_department = #{demandDepartment},</if>
187             <if test="whetherToCollect != null">whether_to_collect = #{whetherToCollect},</if>
188             <if test="defaultValue != null">default_value = #{defaultValue},</if>
189             <if test="productModel != null">product_model = #{productModel},</if>
190
191         </trim>
192         where id = #{id}
193     </update>
194
195     <delete id="deleteDaCollectionParamConfById" parameterType="Long">
196         delete from da_collection_param_conf where id = #{id}
197     </delete>
198
199     <delete id="deleteDaCollectionParamConfByIds" parameterType="String">
200         delete from da_collection_param_conf where id in 
201         <foreach item="id" collection="array" open="(" separator="," close=")">
202             #{id}
203         </foreach>
204     </delete>
205 </mapper>