unknown 4 年之前
父节点
当前提交
4bea173cac
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      app/Http/Controllers/PracticeManagementController.php

+ 2 - 0
app/Http/Controllers/PracticeManagementController.php

@@ -990,6 +990,8 @@ class PracticeManagementController extends Controller
 
         $patientsQuery->whereRaw('(SELECT COUNT(*) FROM note where note.client_id = client.id) > 0');
 
+        $patientsQuery->whereRaw('((SELECT COUNT(*) FROM note where note.client_id = client.id AND is_bill_closed IS NOT true) != 0 && (SELECT COUNT(*) FROM note where note.client_id = client.id AND is_claim_closed IS NOT true) !=0)');
+
         $patientsQuery->orderBy('notes_without_claiming_closed', 'DESC');
 
         $patients = $patientsQuery->paginate(50);