Browse Source

医生缺陷列表总数返回为0bug修改

zhanghang 3 năm trước cách đây
mục cha
commit
677cf149c0
1 tập tin đã thay đổi với 18 bổ sung6 xóa
  1. 18 6
      src/main/resources/mapper/BehospitalInfoMapper.xml

+ 18 - 6
src/main/resources/mapper/BehospitalInfoMapper.xml

@@ -20515,18 +20515,30 @@
                 <![CDATA[ AND a.leave_hospital_date <= #{getDoctorDetailPageVO.endDate}]]>
             </if>
         </if>
-        <if test="getDoctorDetailPageVO.deptName != null and getDoctorDetailPageVO.deptName != ''">
-            AND a.beh_dept_name  =  #{getDoctorDetailPageVO.deptName}
+        <if test="getDoctorDetailPageVO.deptName != null and getDoctorDetailPageVO.deptName != '' and getDoctorDetailPageVO.deptName != '-0'">
+            AND a.beh_dept_name = #{getDoctorDetailPageVO.deptName}
         </if>
-        <if test="getDoctorDetailPageVO.doctorName != null and getDoctorDetailPageVO.doctorName != ''">
-            AND a.doctor_name = #{getDoctorDetailPageVO.doctorName}
+        <if test="getDoctorDetailPageVO.deptName == '-0'">
+            AND (a.beh_dept_name IS NULL OR a.beh_dept_name = '' OR a.beh_dept_name = '-')
         </if>
-        <if test="getDoctorDetailPageVO.deptId != null and getDoctorDetailPageVO.deptId != ''">
+        <if test="getDoctorDetailPageVO.deptId != null and getDoctorDetailPageVO.deptId != '' and getDoctorDetailPageVO.deptId != '-0'">
             AND a.beh_dept_id = #{getDoctorDetailPageVO.deptId}
         </if>
-        <if test="getDoctorDetailPageVO.doctorId != null and getDoctorDetailPageVO.doctorId != ''">
+        <if test="getDoctorDetailPageVO.deptId == '-0'">
+            AND (a.beh_dept_id IS NULL OR a.beh_dept_id = '' OR a.beh_dept_id = '-')
+        </if>
+        <if test="getDoctorDetailPageVO.doctorId != null and getDoctorDetailPageVO.doctorId != '' and getDoctorDetailPageVO.doctorId != '-0'">
             AND a.doctor_id = #{getDoctorDetailPageVO.doctorId}
         </if>
+        <if test="getDoctorDetailPageVO.doctorId == '-0'">
+            AND (a.doctor_id IS NULL OR a.doctor_id = '' OR a.doctor_id = '-')
+        </if>
+        <if test="getDoctorDetailPageVO.doctorName != null and getDoctorDetailPageVO.doctorName != '' and getDoctorDetailPageVO.doctorName != '-0' ">
+            AND a.doctor_name =  #{getDoctorDetailPageVO.doctorName}
+        </if>
+        <if test="getDoctorDetailPageVO.doctorName == '-0'">
+            AND (a.doctor_name IS NULL OR a.doctor_name = '' OR a.doctor_name = '-')
+        </if>
         <if test="getDoctorDetailPageVO.isReject != null">
             AND d.is_reject = #{getDoctorDetailPageVO.isReject}
         </if>