admin
2024-07-26 5f75515d78809c336cb1a004a8cacf53c982344b
提交 | 用户 | 时间
0aaaba 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.bs.formulaChildInfoTemp.mapper.BsFormulaChildInfoTempMapper">
6     
7     <resultMap type="BsFormulaChildInfoTemp" id="BsFormulaChildInfoTempResult">
8         <result property="id"    column="id"    />
9         <result property="sfcCode"    column="sfc_code"    />
10         <result property="lineCode"    column="line_code"    />
11         <result property="processesCode"    column="processes_code"    />
12         <result property="productCode"    column="product_code"    />
13         <result property="operationSteps"    column="operation_steps"    />
14         <result property="techRequirement"    column="tech_requirement"    />
15         <result property="operationType"    column="operation_type"    />
16         <result property="stepSort"    column="step_sort"    />
17         <result property="paramCode"    column="param_code"    />
18         <result property="materialCode"    column="material_code"    />
19         <result property="formulaCode"    column="formula_code"    />
20         <result property="picture"    column="picture"    />
21         <result property="remarks"    column="remarks"    />
22         <result property="createUser"    column="create_user"    />
23         <result property="createTime"    column="create_time"    />
24         <result property="updateUser"    column="update_user"    />
25         <result property="updateTime"    column="update_time"    />
26         <result property="spareField1"    column="spare_field1"    />
27         <result property="spareField2"    column="spare_field2"    />
28         <result property="spareField3"    column="spare_field3"    />
29         <result property="spareField4"    column="spare_field4"    />
30         <result property="collectData"    column="collect_data"    />
31         <result property="results"    column="results"    />
32         <result property="ngTimes"    column="ng_times"    />
33         <result property="ngCollectData"    column="ng_collect_data"    />
34         <result property="ngResults"    column="ng_results"    />
6e3e50 35         <result property="childId"    column="child_id"    />
A 36
0aaaba 37     </resultMap>
A 38
39     <sql id="selectBsFormulaChildInfoTempVo">
6e3e50 40         select id, sfc_code, child_id,line_code, processes_code, product_code, operation_steps, tech_requirement, operation_type, step_sort, param_code, material_code, formula_code, picture, remarks, create_user, create_time, update_user, update_time, spare_field1, spare_field2, spare_field3, spare_field4, collect_data, results, ng_times, ng_collect_data, ng_results from bs_formula_child_info_temp
0aaaba 41     </sql>
A 42
43     <select id="selectBsFormulaChildInfoTempList" parameterType="BsFormulaChildInfoTemp" resultMap="BsFormulaChildInfoTempResult">
44         <include refid="selectBsFormulaChildInfoTempVo"/>
45         <where>  
46             <if test="sfcCode != null  and sfcCode != ''"> and sfc_code = #{sfcCode}</if>
47             <if test="lineCode != null  and lineCode != ''"> and line_code = #{lineCode}</if>
48             <if test="processesCode != null  and processesCode != ''"> and processes_code = #{processesCode}</if>
49             <if test="productCode != null  and productCode != ''"> and product_code = #{productCode}</if>
50             <if test="operationSteps != null  and operationSteps != ''"> and operation_steps = #{operationSteps}</if>
51             <if test="techRequirement != null  and techRequirement != ''"> and tech_requirement = #{techRequirement}</if>
52             <if test="operationType != null  and operationType != ''"> and operation_type = #{operationType}</if>
53             <if test="stepSort != null  and stepSort != ''"> and step_sort = #{stepSort}</if>
54             <if test="paramCode != null  and paramCode != ''"> and param_code = #{paramCode}</if>
55             <if test="materialCode != null  and materialCode != ''"> and material_code = #{materialCode}</if>
56             <if test="formulaCode != null  and formulaCode != ''"> and formula_code = #{formulaCode}</if>
57             <if test="picture != null  and picture != ''"> and picture = #{picture}</if>
58             <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
59             <if test="createUser != null  and createUser != ''"> and create_user = #{createUser}</if>
60             <if test="updateUser != null  and updateUser != ''"> and update_user = #{updateUser}</if>
61             <if test="spareField1 != null  and spareField1 != ''"> and spare_field1 = #{spareField1}</if>
62             <if test="spareField2 != null  and spareField2 != ''"> and spare_field2 = #{spareField2}</if>
63             <if test="spareField3 != null  and spareField3 != ''"> and spare_field3 = #{spareField3}</if>
64             <if test="spareField4 != null  and spareField4 != ''"> and spare_field4 = #{spareField4}</if>
65             <if test="collectData != null  and collectData != ''"> and collect_data = #{collectData}</if>
66             <if test="results != null  and results != ''"> and results = #{results}</if>
67             <if test="ngTimes != null "> and ng_times = #{ngTimes}</if>
68             <if test="ngCollectData != null  and ngCollectData != ''"> and ng_collect_data = #{ngCollectData}</if>
69             <if test="ngResults != null  and ngResults != ''"> and ng_results = #{ngResults}</if>
70         </where>
71     </select>
72     
73     <select id="selectBsFormulaChildInfoTempById" parameterType="Long" resultMap="BsFormulaChildInfoTempResult">
74         <include refid="selectBsFormulaChildInfoTempVo"/>
75         where id = #{id}
76     </select>
77         
78     <insert id="insertBsFormulaChildInfoTemp" parameterType="BsFormulaChildInfoTemp" useGeneratedKeys="true" keyProperty="id">
79         insert into bs_formula_child_info_temp
80         <trim prefix="(" suffix=")" suffixOverrides=",">
81             <if test="sfcCode != null">sfc_code,</if>
82             <if test="lineCode != null">line_code,</if>
83             <if test="processesCode != null">processes_code,</if>
84             <if test="productCode != null">product_code,</if>
85             <if test="operationSteps != null">operation_steps,</if>
86             <if test="techRequirement != null">tech_requirement,</if>
87             <if test="operationType != null">operation_type,</if>
88             <if test="stepSort != null">step_sort,</if>
89             <if test="paramCode != null">param_code,</if>
90             <if test="materialCode != null">material_code,</if>
91             <if test="formulaCode != null">formula_code,</if>
92             <if test="picture != null">picture,</if>
93             <if test="remarks != null">remarks,</if>
94             <if test="createUser != null">create_user,</if>
95             <if test="createTime != null">create_time,</if>
96             <if test="updateUser != null">update_user,</if>
97             <if test="updateTime != null">update_time,</if>
98             <if test="spareField1 != null">spare_field1,</if>
99             <if test="spareField2 != null">spare_field2,</if>
100             <if test="spareField3 != null">spare_field3,</if>
101             <if test="spareField4 != null">spare_field4,</if>
102             <if test="collectData != null">collect_data,</if>
103             <if test="results != null">results,</if>
104             <if test="ngTimes != null">ng_times,</if>
105             <if test="ngCollectData != null">ng_collect_data,</if>
106             <if test="ngResults != null">ng_results,</if>
6e3e50 107             <if test="childId != null">child_id,</if>
A 108         </trim>
0aaaba 109         <trim prefix="values (" suffix=")" suffixOverrides=",">
A 110             <if test="sfcCode != null">#{sfcCode},</if>
111             <if test="lineCode != null">#{lineCode},</if>
112             <if test="processesCode != null">#{processesCode},</if>
113             <if test="productCode != null">#{productCode},</if>
114             <if test="operationSteps != null">#{operationSteps},</if>
115             <if test="techRequirement != null">#{techRequirement},</if>
116             <if test="operationType != null">#{operationType},</if>
117             <if test="stepSort != null">#{stepSort},</if>
118             <if test="paramCode != null">#{paramCode},</if>
119             <if test="materialCode != null">#{materialCode},</if>
120             <if test="formulaCode != null">#{formulaCode},</if>
121             <if test="picture != null">#{picture},</if>
122             <if test="remarks != null">#{remarks},</if>
123             <if test="createUser != null">#{createUser},</if>
124             <if test="createTime != null">#{createTime},</if>
125             <if test="updateUser != null">#{updateUser},</if>
126             <if test="updateTime != null">#{updateTime},</if>
127             <if test="spareField1 != null">#{spareField1},</if>
128             <if test="spareField2 != null">#{spareField2},</if>
129             <if test="spareField3 != null">#{spareField3},</if>
130             <if test="spareField4 != null">#{spareField4},</if>
131             <if test="collectData != null">#{collectData},</if>
132             <if test="results != null">#{results},</if>
133             <if test="ngTimes != null">#{ngTimes},</if>
134             <if test="ngCollectData != null">#{ngCollectData},</if>
135             <if test="ngResults != null">#{ngResults},</if>
6e3e50 136             <if test="childId != null">#{childId},</if>
A 137
138         </trim>
0aaaba 139     </insert>
A 140
141     <update id="updateBsFormulaChildInfoTemp" parameterType="BsFormulaChildInfoTemp">
142         update bs_formula_child_info_temp
143         <trim prefix="SET" suffixOverrides=",">
144             <if test="sfcCode != null">sfc_code = #{sfcCode},</if>
145             <if test="lineCode != null">line_code = #{lineCode},</if>
146             <if test="processesCode != null">processes_code = #{processesCode},</if>
147             <if test="productCode != null">product_code = #{productCode},</if>
148             <if test="operationSteps != null">operation_steps = #{operationSteps},</if>
149             <if test="techRequirement != null">tech_requirement = #{techRequirement},</if>
150             <if test="operationType != null">operation_type = #{operationType},</if>
151             <if test="stepSort != null">step_sort = #{stepSort},</if>
152             <if test="paramCode != null">param_code = #{paramCode},</if>
153             <if test="materialCode != null">material_code = #{materialCode},</if>
154             <if test="formulaCode != null">formula_code = #{formulaCode},</if>
155             <if test="picture != null">picture = #{picture},</if>
156             <if test="remarks != null">remarks = #{remarks},</if>
157             <if test="createUser != null">create_user = #{createUser},</if>
158             <if test="createTime != null">create_time = #{createTime},</if>
159             <if test="updateUser != null">update_user = #{updateUser},</if>
160             <if test="updateTime != null">update_time = #{updateTime},</if>
161             <if test="spareField1 != null">spare_field1 = #{spareField1},</if>
162             <if test="spareField2 != null">spare_field2 = #{spareField2},</if>
163             <if test="spareField3 != null">spare_field3 = #{spareField3},</if>
164             <if test="spareField4 != null">spare_field4 = #{spareField4},</if>
165             <if test="collectData != null">collect_data = #{collectData},</if>
166             <if test="results != null">results = #{results},</if>
167             <if test="ngTimes != null">ng_times = #{ngTimes},</if>
168             <if test="ngCollectData != null">ng_collect_data = #{ngCollectData},</if>
169             <if test="ngResults != null">ng_results = #{ngResults},</if>
6e3e50 170             <if test="childId != null">child_id = #{childId},</if>
A 171
0aaaba 172         </trim>
A 173         where id = #{id}
174     </update>
175
176     <delete id="deleteBsFormulaChildInfoTempById" parameterType="Long">
177         delete from bs_formula_child_info_temp where id = #{id}
178     </delete>
179
180     <delete id="deleteBsFormulaChildInfoTempByIds" parameterType="String">
181         delete from bs_formula_child_info_temp where id in 
182         <foreach item="id" collection="array" open="(" separator="," close=")">
183             #{id}
184         </foreach>
185     </delete>
186 </mapper>