|
@@ -94,47 +94,6 @@ public interface PatientDao {
|
|
|
"</script>")
|
|
|
Patient getPatientInfo(@Param("inpatientNo") String inpatientNo, @Param("table") String table, @Param("times") Integer times);
|
|
|
|
|
|
- @Select("select inpatientNo=rtrim(a.inpatient_no),a.admiss_times,a.med_type,b.social_no, " +
|
|
|
- "name=rtrim(a.name),sex=isnull(a.sex, b.sex),act_ipt_days=(datediff(day, admiss_date, getdate())), " +
|
|
|
- "birthDate=(convert(varchar(10), birth_date, 21)),home_tel=rtrim(b.home_tel), " +
|
|
|
- "admissPhysician=rtrim(a.admiss_physician), " +
|
|
|
- "admissPhysicianName=rtrim((select name FROM a_employee_mi WHERE code = a.admiss_physician)), " +
|
|
|
- "referPhysician=rtrim(a.refer_physician),a.dise_code,a.dise_name, " +
|
|
|
- "referPhysicianName=rtrim((select name FROM a_employee_mi WHERE code = a.refer_physician)), " +
|
|
|
- "admissDiagStr=rtrim(isnull(a.admiss_diag_str,'')), " +
|
|
|
- "clinicDiagStr=rtrim(isnull(a.clinic_diag_str,'')), " +
|
|
|
- "admissWard=rtrim(isnull(a.ward,a.admiss_ward)), " +
|
|
|
- "admissWardName=(select rtrim(name) from zd_unit_code where code=a.ward), " +
|
|
|
- "admissDept=rtrim(a.admiss_dept), a.matn_type,smallDept=rtrim(a.small_dept), " +
|
|
|
- "smallDeptName=rtrim((select name from zd_unit_code where code=small_dept)), " +
|
|
|
- "admiss_date,ybRegisterDate=isnull(yb_register_date, admiss_date), " +
|
|
|
- "responceType=rtrim(isnull(a.responce_type, '01')), " +
|
|
|
- "responceTypeName=(select rtrim(name) from zy_zd_responce_type where code = isnull(a.responce_type, '01')), " +
|
|
|
- "zkWard=rtrim(a.zk_ward),ward=(a.ward),a.latechb_flag,a.pret_flag,ledgerSn=a.times_billed, " +
|
|
|
- "admissStatus=rtrim(a.admiss_status), " +
|
|
|
- "dismissOrder=(select count(1) from yz_act_order y where y.inpatient_no=b.inpatient_no " +
|
|
|
- "and y.admiss_times=a.admiss_times and status_flag>'1' and isnull(group_no,'00')='00' " +
|
|
|
- "and order_code in ('06026','06053','05973')), " +
|
|
|
- "disDiagStatus=(select RTRIM(dis_diag_status) from zy_dis_diag_yb where inpatient_no=a.inpatient_no " +
|
|
|
- "and admiss_times=a.admiss_times and dis_diag_no=1), " +
|
|
|
- "operation=rtrim(a.operation),a.zy_serial_no, " +
|
|
|
- "bedNo=rtrim(a.bed_no),a.admdvs, " +
|
|
|
- "mdtrtId=(select mdtrt_id from t_si_pat_info where pat_no=a.inpatient_no and times=a.admiss_times and ledger_sn=a.times_billed), " +
|
|
|
- "injurySerialNo=(select serial_no from t_injury_si_pat_info where pat_no=a.inpatient_no " +
|
|
|
- "and times=a.admiss_times and ledger_sn=a.times_billed), " +
|
|
|
- "chargeYb=(select isnull(charge_yb, '0.00') from zy_ledger_file where inpatient_no=a.inpatient_no " +
|
|
|
- "and admiss_times=a.admiss_times and ledger_sn=a.times_billed), " +
|
|
|
- "totalCharge=(select rtrim(isnull(total_charge, '0.00')) from zy_ledger_file where inpatient_no=a.inpatient_no " +
|
|
|
- "and admiss_times=a.admiss_times and ledger_sn=a.times_billed), " +
|
|
|
- "balance=RTRIM((select balance+charge_yb from zy_ledger_file where inpatient_no=a.inpatient_no and " +
|
|
|
- "admiss_times=a.admiss_times and ledger_sn=a.times_billed)), " +
|
|
|
- "injuryArea=(select injury_area from t_injury_si_pat_info where pat_no=a.inpatient_no " +
|
|
|
- "and times=a.admiss_times and ledger_sn=a.times_billed) " +
|
|
|
- "FROM ${table} a, a_patient_mi b WHERE a.inpatient_no=#{patNo} and a.admiss_times=#{times} AND b.inpatient_no=a.inpatient_no")
|
|
|
- Patient getPatientInfoForHrg(@Param("patNo") String patNo,
|
|
|
- @Param("times") Integer times,
|
|
|
- @Param("table") String table);
|
|
|
-
|
|
|
@Select("select dis_diag_no, " +
|
|
|
"rtrim(dis_diag) disDiag, " +
|
|
|
"rtrim(dis_diag_comment) disDiagComment, " +
|