lgy 6 년 전
부모
커밋
90e215de8f
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      application/inter/controller/Reciveremote.php

+ 2 - 2
application/inter/controller/Reciveremote.php

@@ -110,7 +110,7 @@ class Reciveremote extends Base
                             break;
                         case 'exam_status':
                             if($v != 10){
-                                $where .= " and e.exam_status=".$v;
+                                $where .= " and ra.report_status=".$v;
                             }
                             break;
                     }
@@ -142,7 +142,7 @@ class Reciveremote extends Base
 //            }
             log::record($sql);
             $list = DB::query($sql);
-            $csql = "SELECT count(1) from exams as e,remote_application as ra,patient_infos as p,report as r where (ra.remote_doctor_id='".$doctor['id']."' or ra.remote_doctor_id='') and r.remote_application_id=ra.id and ra.exam_id=e.id and ra.report_status !='' and e.patient_id=p.id and r.exam_id=e.id and ra.remote_institution_id='" . $doctor['institution_id']."'".$where;
+            $csql = "SELECT count(1) from exams as e,remote_application as ra,patient_infos as p,report as r where (ra.remote_doctor_id='".$doctor['id']."' or ra.remote_doctor_id='') and r.remote_application_id=ra.id and ra.exam_id=e.id and ra.report_status !='' and e.patient_id=p.id and r.exam_id=e.id and ra.remote_institution_id='" . $doctor['institution_id']."'".$where.$dwhere;
             $count = DB::query($csql);
             foreach ($list as $k => $v) {
                 $cache_key = $doctor['id'].'_'.$v['id'];