Procházet zdrojové kódy

bugFix 解决表达式错误 导致CPU占用率飙升的问题

xiahan před 1 rokem
rodič
revize
771c1119e1

+ 15 - 14
cx-aps/cx-aps-common/src/main/resources/mybatis/ApsProcessOperationProcessEquDao.xml

@@ -408,20 +408,21 @@
     <select id="getConflictId" resultType="com.rongwei.bsentity.domain.ApsProcessOperationProcessEquDo">
         select apope.*
         from aps_process_operation_process_equ apope
-                left join aps_process_operation app on apope.PROCESSID=app.DELETED='0'
-            <where>
-                apope.DELETED='0'
-                AND apope.ID != #{id}
-                AND apope.PROCESSDEVICEID =#{equId}
-                AND (
-                (#{startTime}&lt; apope.PLANENDDATE and #{endTime} > apope.PLANSTARTDATE)
-                  or
-                (apope.PLANSTARTDATE &lt; #{endTime} and apope.PLANENDDATE > #{startTime})
-                )
-                <if test="processway == '合并加工'">
-                    and ((app.PROCESSWAY != '合并加工') or(app.PROCESSWAY = '合并加工' and apope.PLANSTARTDATE!= #{startTime}) )
-                </if>
-            </where>
+        left join aps_process_operation app on apope.PROCESSID = app.ID and app.DELETED='0'
+        <where>
+            apope.DELETED='0'
+            AND apope.ID != #{id}
+            AND apope.PROCESSDEVICEID =#{equId}
+            AND (
+            (#{startTime}&lt; apope.PLANENDDATE and #{endTime} > apope.PLANSTARTDATE)
+            or
+            (apope.PLANSTARTDATE &lt; #{endTime} and apope.PLANENDDATE > #{startTime})
+            )
+            <if test="processway == '合并加工'">
+                and ((app.PROCESSWAY != '合并加工') or(app.PROCESSWAY = '合并加工' and apope.PLANSTARTDATE!=
+                #{startTime}) )
+            </if>
+        </where>
     </select>
     <select id="getWorkshopAndDeviceByFactoryId" resultType="com.rongwei.bsentity.vo.GanttVos">
         SELECT