xuxiaofei пре 2 година
родитељ
комит
8647bae70e

+ 3 - 3
zd-modules/zd-airbottle/src/main/resources/mapper/airbottle/QpBottleStorageOutMapper.xml

@@ -33,9 +33,7 @@
                t.storage_id, t.car_id, t.car_number, t.transport_id, t.transport_name,
                t.dispose_userid, t.dispose_username, t.dispose_time, t.complete_time,
                t.complete_userid, t.complete_username, t.pressure,t.out_status,
-               (select l.room room from lab_subject s,lab_subject_layout l where s.layout_id =l.id and s.id=
-               ( select location_id from qp_bottle_storage bs , qp_task ta where bs.id=t.storage_id
-                                                                            and bs.task_id = ta.id) ) room
+               (select fl.room_num from lab_build_floor_layout fl where fl.sub_id=ta.location_id) room
         from  qp_bottle_storage_out  t
             LEFT JOIN qp_bottle_storage bs on t.storage_id=bs.id
             LEFT JOIN qp_task ta on bs.task_id=ta.id
@@ -44,6 +42,7 @@
     </sql>
     <select id="selectQpBottleStorageOutList" parameterType="com.zd.airbottle.domain.vo.QpBottleStorageOutVO" resultMap="QpBottleStorageOutResult">
         <include refid="selectQpBottleStorageOutListVo"/>
+        <where>
             <if test="searchValue != null  and searchValue != ''">
                 and ( t.apply_user_name like concat('%', #{searchValue}, '%')
                 or t.phone like concat('%', #{searchValue}, '%')
@@ -74,6 +73,7 @@
                 #{id}
             </foreach>
          </if>
+        </where>
         <!-- 数据范围过滤 -->
         ${params.dataScope}
         order by t.create_time desc

+ 2 - 2
zd-modules/zd-airbottle/src/main/resources/mapper/airbottle/QpFlowDetailMapper.xml

@@ -69,8 +69,8 @@
             <if test="flowType != null ">and t.flow_type = #{flowType}</if>
             <if test="userName != null  and userName != ''">and t.user_name like concat('%', #{userName}, '%')</if>
             <if test="userTelephone != null  and userTelephone != ''">and t.user_telephone = #{userTelephone}</if>
-            <if test="deptId != null ">and ( dept_id in (SELECT dt.dept_id FROM sys_dept dt WHERE find_in_set(#{deptId}
-                ,ancestors )) or dept_id = #{deptId} )
+            <if test="deptId != null ">and ( t.dept_id in (SELECT dt.dept_id FROM sys_dept dt WHERE find_in_set(#{deptId}
+                ,ancestors )) or t.dept_id = #{deptId} )
             </if>
             <!-- 数据范围过滤 -->
             ${params.dataScope}

+ 4 - 0
zd-modules/zd-airbottle/src/main/resources/mapper/airbottle/QpQualificationApplyMapper.xml

@@ -98,6 +98,10 @@
             <if test="deptId != null "> and t.dept_id = #{deptId}</if>
             <if test="deptName != null  and deptName != ''"> and t.dept_name like concat('%', #{deptName}, '%')</if>
             <if test="phone != null  and phone != ''"> and t.phone = #{phone}</if>
+            <if test="startTime != null  and endTime != null">
+                and (t.start_time &lt;= #{startTime}  and t.end_time &gt;= #{startTime})
+                or (t.start_time &lt;= #{endTime}  and t.end_time &gt;= #{endTime})
+            </if>
             <if test="startTime != null "> and t.start_time &gt;= #{startTime}</if>
             <if test="endTime != null "> and t.end_time &lt;= #{endTime}</if>
             <if test="gasUse != null  and gasUse != ''"> and t.gas_use = #{gasUse}</if>

+ 4 - 0
zd-modules/zd-airbottle/src/main/resources/mapper/airbottle/QpUsegasApplyMapper.xml

@@ -70,6 +70,10 @@
             <if test="deptId != null "> and t.dept_id = #{deptId}</if>
             <if test="deptName != null  and deptName != ''"> and t.dept_name like concat('%', #{deptName}, '%')</if>
             <if test="phone != null  and phone != ''"> and t.phone = #{phone}</if>
+            <if test="startTime != null  and endTime != null ">
+                and (t.start_time &lt;= #{startTime}  and t.end_time &gt;= #{startTime})
+                or (t.start_time &lt;= #{endTime}  and t.end_time &gt;= #{endTime})
+            </if>
             <if test="startTime != null "> and t.start_time &gt;= #{startTime}</if>
             <if test="endTime != null "> and t.end_time &lt;= #{endTime}</if>
             <if test="gasUse != null  and gasUse != ''"> and t.gas_use = #{gasUse}</if>