|
@ -66,7 +66,7 @@ public interface PatientDao extends PagingAndSortingRepository<Patient, Long> {
|
|
|
@Query("select distinct p.openid from Patient p where p.openid is not null and p.openid <> '' ")
|
|
|
List<String> findOpenids();
|
|
|
|
|
|
@Query(value=" select p.* from wlyy_patient p LEFT JOIN wlyy_sign_family s on s.patient = p.code RIGHT JOIN wlyy_sign_patient_label_info sp on sp.patient = p.code WHERE sp.status = 1 and s.status > 0 and sp.label_type = 3 and (sp.label = 1 or sp.label = 2) and s.admin_team_code = ?1 and (s.doctor = ?2 or s.doctor_health =?2))",nativeQuery = true)
|
|
|
@Query(value=" select DISTINCT p.* from wlyy_patient p LEFT JOIN wlyy_sign_family s on s.patient = p.code RIGHT JOIN wlyy_sign_patient_label_info sp on sp.patient = p.code WHERE sp.status = 1 and s.status > 0 and sp.label_type = 3 and (sp.label = 1 or sp.label = 2) and s.admin_team_code = ?1 and (s.doctor = ?2 or s.doctor_health =?2)",nativeQuery = true)
|
|
|
List<Patient> findAllSignPatientTeamcode(String teamcode, String doctorcode);
|
|
|
|
|
|
@Query(value="SELECT DISTINCT t.* FROM wlyy_sign_family t1,wlyy_patient t WHERE t.`code`=t1.patient AND t1.STATUS>0 AND " +
|