|
@@ -66,6 +66,8 @@ public interface PatientDao {
|
|
|
"admissPhysician=rtrim(a.admiss_physician),b.psn_cert_type, " +
|
|
|
"insutype=(select top 1 insutype from t_si_pat_info with(nolock) where pat_no=#{inpatientNo} and " +
|
|
|
"times=a.admiss_times order by ledger_sn desc), " +
|
|
|
+ "psnType=(select max(psn_type) from t_si_pat_info with(nolock) where pat_no=#{inpatientNo} and times=a.admiss_times), " +
|
|
|
+ "psnIdetType=(select max(psn_idet_type) from t_si_pat_info with(nolock) where pat_no=#{inpatientNo} and times=a.admiss_times), " +
|
|
|
"admissPhysicianName=rtrim((select name FROM a_employee_mi WHERE code = a.admiss_physician)), " +
|
|
|
"referPhysician=rtrim(a.refer_physician), " +
|
|
|
"referPhysicianName=rtrim((select name FROM a_employee_mi WHERE code = a.refer_physician)), " +
|
|
@@ -107,6 +109,10 @@ public interface PatientDao {
|
|
|
"</script>")
|
|
|
Patient getPatientInfo(@Param("inpatientNo") String inpatientNo, @Param("table") String table, @Param("times") Integer times);
|
|
|
|
|
|
+ @Select("select max(insuplc_admdvs) from t_si_pat_info where pat_no=#{patNo} " +
|
|
|
+ "and times=#{times} and ledger_sn=#{ledgerSn}")
|
|
|
+ Integer getPatAdmdvs(String patNo, int times, int ledgerSn);
|
|
|
+
|
|
|
@Select("select parent_code from t_region where code=#{code}")
|
|
|
Integer selectParentRegion(Integer code);
|
|
|
|