懒羊羊
2024-03-21 32483a44c0ee1c4d605730ef6f894d43f76b3048
提交 | 用户 | 时间
e57a89 1 <?xml version="1.0" encoding="UTF-8" ?>
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"    />
17         <result property="Descriptives"    column="Descriptives"    />
18         <result property="paramUpper"    column="param_upper"    />
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_field_1"    />
30         <result property="spareField2"    column="spare_field_2"    />
31         <result property="spareField3"    column="spare_field_3"    />
32         <result property="spareField4"    column="spare_field_4"    />
679fb5 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"    />
49c784 42         <result property="productModel"    column="product_model"    />
43
e57a89 44     </resultMap>
45
46     <sql id="selectDaCollectionParamConfVo">
49c784 47         select id, 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_field_1, spare_field_2, spare_field_3, spare_field_4, processes_name, device, project, accuracy, array_length, acquisition_frequency, demand_department, whether_to_collect, default_value from da_collection_param_conf
e57a89 48     </sql>
49
50     <select id="selectDaCollectionParamConfList" parameterType="DaCollectionParamConf" resultMap="DaCollectionParamConfResult">
51         <include refid="selectDaCollectionParamConfVo"/>
52         <where>  
53             <if test="processesCode != null  and processesCode != ''"> and processes_code like concat('%', #{processesCode}, '%')</if>
54             <if test="parameterSetCode != null  and parameterSetCode != ''"> and parameter_set_code like concat('%', #{parameterSetCode}, '%')</if>
55             <if test="parameterSetName != null  and parameterSetName != ''"> and parameter_set_name like concat('%', #{parameterSetName}, '%')</if>
56             <if test="collectParameterId != null  and collectParameterId != ''"> and collect_parameter_id like concat('%', #{collectParameterId}, '%')</if>
57             <if test="collectParameterName != null  and collectParameterName != ''"> and collect_parameter_name like concat('%', #{collectParameterName}, '%')</if>
58             <if test="contrastParameterFlag != null  and contrastParameterFlag != ''"> and contrast_parameter_flag like concat('%', #{contrastParameterFlag}, '%')</if>
59             <if test="collectParameterType != null  and collectParameterType != ''"> and collect_parameter_type like concat('%', #{collectParameterType}, '%')</if>
60             <if test="productCode != null  and productCode != ''"> and product_code like concat('%', #{productCode}, '%')</if>
32483a 61             <if test="gatherAddress != null  and gatherAddress != ''"> and gather_address like concat('%', #{gatherAddress}, '%')</if>
62
e57a89 63         </where>
64     </select>
65     
66     <select id="selectDaCollectionParamConfById" parameterType="Long" resultMap="DaCollectionParamConfResult">
67         <include refid="selectDaCollectionParamConfVo"/>
68         where id = #{id}
69     </select>
70         
71     <insert id="insertDaCollectionParamConf" parameterType="DaCollectionParamConf">
72         insert into da_collection_param_conf
73         <trim prefix="(" suffix=")" suffixOverrides=",">
74             <if test="id != null">id,</if>
75             <if test="processesCode != null">processes_code,</if>
76             <if test="parameterSetCode != null">parameter_set_code,</if>
77             <if test="parameterSetName != null">parameter_set_name,</if>
78             <if test="collectParameterId != null">collect_parameter_id,</if>
79             <if test="collectParameterName != null">collect_parameter_name,</if>
80             <if test="contrastParameterFlag != null">contrast_parameter_flag,</if>
81             <if test="collectParameterType != null">collect_parameter_type,</if>
82             <if test="collectParameterUnit != null">collect_parameter_unit,</if>
83             <if test="Descriptives != null">Descriptives,</if>
84             <if test="paramUpper != null">param_upper,</if>
85             <if test="paramLower != null">param_lower,</if>
86             <if test="paramCentral != null">param_Central,</if>
87             <if test="productCode != null">product_code,</if>
88             <if test="gatherAddress != null">gather_address,</if>
89             <if test="gatherSequence != null">gather_sequence,</if>
90             <if test="remarks != null">remarks,</if>
91             <if test="createUser != null">create_user,</if>
92             <if test="createTime != null">create_time,</if>
93             <if test="updateUser != null">update_user,</if>
94             <if test="updateTime != null">update_time,</if>
95             <if test="spareField1 != null">spare_field_1,</if>
96             <if test="spareField2 != null">spare_field_2,</if>
97             <if test="spareField3 != null">spare_field_3,</if>
98             <if test="spareField4 != null">spare_field_4,</if>
679fb5 99             <if test="processesName != null">processes_name,</if>
100             <if test="device != null">device,</if>
101             <if test="project != null">project,</if>
102             <if test="accuracy != null">accuracy,</if>
103             <if test="arrayLength != null">array_length,</if>
104             <if test="acquisitionFrequency != null">acquisition_frequency,</if>
105             <if test="demandDepartment != null">demand_department,</if>
106             <if test="whetherToCollect != null">whether_to_collect,</if>
107             <if test="defaultValue != null">default_value,</if>
49c784 108             <if test="productModel != null">product_model,</if>
109
110         </trim>
e57a89 111         <trim prefix="values (" suffix=")" suffixOverrides=",">
112             <if test="id != null">#{id},</if>
113             <if test="processesCode != null">#{processesCode},</if>
114             <if test="parameterSetCode != null">#{parameterSetCode},</if>
115             <if test="parameterSetName != null">#{parameterSetName},</if>
116             <if test="collectParameterId != null">#{collectParameterId},</if>
117             <if test="collectParameterName != null">#{collectParameterName},</if>
118             <if test="contrastParameterFlag != null">#{contrastParameterFlag},</if>
119             <if test="collectParameterType != null">#{collectParameterType},</if>
120             <if test="collectParameterUnit != null">#{collectParameterUnit},</if>
121             <if test="Descriptives != null">#{Descriptives},</if>
122             <if test="paramUpper != null">#{paramUpper},</if>
123             <if test="paramLower != null">#{paramLower},</if>
124             <if test="paramCentral != null">#{paramCentral},</if>
125             <if test="productCode != null">#{productCode},</if>
126             <if test="gatherAddress != null">#{gatherAddress},</if>
127             <if test="gatherSequence != null">#{gatherSequence},</if>
128             <if test="remarks != null">#{remarks},</if>
129             <if test="createUser != null">#{createUser},</if>
130             <if test="createTime != null">#{createTime},</if>
131             <if test="updateUser != null">#{updateUser},</if>
132             <if test="updateTime != null">#{updateTime},</if>
133             <if test="spareField1 != null">#{spareField1},</if>
134             <if test="spareField2 != null">#{spareField2},</if>
135             <if test="spareField3 != null">#{spareField3},</if>
136             <if test="spareField4 != null">#{spareField4},</if>
679fb5 137             <if test="processesName != null">#{processesName},</if>
138             <if test="device != null">#{device},</if>
139             <if test="project != null">#{project},</if>
140             <if test="accuracy != null">#{accuracy},</if>
141             <if test="arrayLength != null">#{arrayLength},</if>
142             <if test="acquisitionFrequency != null">#{acquisitionFrequency},</if>
143             <if test="demandDepartment != null">#{demandDepartment},</if>
144             <if test="whetherToCollect != null">#{whetherToCollect},</if>
145             <if test="defaultValue != null">#{defaultValue},</if>
49c784 146             <if test="productModel != null">#{productModel},</if>
147
148         </trim>
e57a89 149     </insert>
150
151     <update id="updateDaCollectionParamConf" parameterType="DaCollectionParamConf">
152         update da_collection_param_conf
153         <trim prefix="SET" suffixOverrides=",">
154             <if test="processesCode != null">processes_code = #{processesCode},</if>
155             <if test="parameterSetCode != null">parameter_set_code = #{parameterSetCode},</if>
156             <if test="parameterSetName != null">parameter_set_name = #{parameterSetName},</if>
157             <if test="collectParameterId != null">collect_parameter_id = #{collectParameterId},</if>
158             <if test="collectParameterName != null">collect_parameter_name = #{collectParameterName},</if>
159             <if test="contrastParameterFlag != null">contrast_parameter_flag = #{contrastParameterFlag},</if>
160             <if test="collectParameterType != null">collect_parameter_type = #{collectParameterType},</if>
161             <if test="collectParameterUnit != null">collect_parameter_unit = #{collectParameterUnit},</if>
162             <if test="Descriptives != null">Descriptives = #{Descriptives},</if>
163             <if test="paramUpper != null">param_upper = #{paramUpper},</if>
164             <if test="paramLower != null">param_lower = #{paramLower},</if>
165             <if test="paramCentral != null">param_Central = #{paramCentral},</if>
166             <if test="productCode != null">product_code = #{productCode},</if>
167             <if test="gatherAddress != null">gather_address = #{gatherAddress},</if>
168             <if test="gatherSequence != null">gather_sequence = #{gatherSequence},</if>
169             <if test="remarks != null">remarks = #{remarks},</if>
170             <if test="createUser != null">create_user = #{createUser},</if>
171             <if test="createTime != null">create_time = #{createTime},</if>
172             <if test="updateUser != null">update_user = #{updateUser},</if>
173             <if test="updateTime != null">update_time = #{updateTime},</if>
174             <if test="spareField1 != null">spare_field_1 = #{spareField1},</if>
175             <if test="spareField2 != null">spare_field_2 = #{spareField2},</if>
176             <if test="spareField3 != null">spare_field_3 = #{spareField3},</if>
177             <if test="spareField4 != null">spare_field_4 = #{spareField4},</if>
679fb5 178             <if test="processesName != null">processes_name = #{processesName},</if>
179             <if test="device != null">device = #{device},</if>
180             <if test="project != null">project = #{project},</if>
181             <if test="accuracy != null">accuracy = #{accuracy},</if>
182             <if test="arrayLength != null">array_length = #{arrayLength},</if>
183             <if test="acquisitionFrequency != null">acquisition_frequency = #{acquisitionFrequency},</if>
184             <if test="demandDepartment != null">demand_department = #{demandDepartment},</if>
185             <if test="whetherToCollect != null">whether_to_collect = #{whetherToCollect},</if>
186             <if test="defaultValue != null">default_value = #{defaultValue},</if>
49c784 187             <if test="productModel != null">product_model = #{productModel},</if>
188
e57a89 189         </trim>
190         where id = #{id}
191     </update>
192
193     <delete id="deleteDaCollectionParamConfById" parameterType="Long">
194         delete from da_collection_param_conf where id = #{id}
195     </delete>
196
197     <delete id="deleteDaCollectionParamConfByIds" parameterType="String">
198         delete from da_collection_param_conf where id in 
199         <foreach item="id" collection="array" open="(" separator="," close=")">
200             #{id}
201         </foreach>
202     </delete>
203 </mapper>