ソースを参照

Merge remote-tracking branch 'origin/dbdx' into dbdx

xuxiaofei 2 年 前
コミット
2edd0be2f1
共有1 個のファイルを変更した4 個の追加1 個の削除を含む
  1. 4 1
      zd-modules/zd-modules-laboratory/src/main/resources/mapper/laboratory/LabRiskPlanAbnormalGroupMapper.xml

+ 4 - 1
zd-modules/zd-modules-laboratory/src/main/resources/mapper/laboratory/LabRiskPlanAbnormalGroupMapper.xml

@@ -158,7 +158,9 @@
 
     <!-- 批量查询实验室预警 -->
     <select id="queryRiskExeRecordList" parameterType="com.zd.laboratory.domain.LabRiskPlanAbnormalGroup" resultType="com.zd.laboratory.domain.LabRiskPlanAbnormalGroup">
-        SELECT g.id, g.group_name, g.subject_id, s.dept_name, CONCAT(s.name,s.room) AS subject_name, g.risk_attribute, g.STATUS, g.create_time, g.create_by, g.update_time
+        SELECT g.id, g.group_name, g.subject_id,
+        (select d.dept_name from sys_dept d where d.dept_id = s.dept_id) dept_name
+        , CONCAT(s.name,s.room) AS subject_name, g.risk_attribute, g.STATUS, g.create_time, g.create_by, g.update_time
         FROM lab_risk_plan_abnormal_group g
         LEFT JOIN lab_subject s ON s.id = g.subject_id
         <where>
@@ -168,6 +170,7 @@
                 or s.name like concat('%', #{searchValue}, '%')
                 )
             </if>
+            <if test="deptId != null ">and s.dept_id = #{deptId}</if>
             <if test="riskAttribute != null ">and g.risk_attribute = #{riskAttribute}</if>
 
             <if test="startTime != null ">