|
|
@@ -399,8 +399,8 @@ public interface UpIdCollectionDao {
|
|
|
" case when yb_name is null then rtrim(ssmc) else rtrim(yb_name) end ssmc," +
|
|
|
" rtrim(mzff) mzff, rtrim(qkjb) qkjb," +
|
|
|
"rtrim(yhqk) yhqk, ssbfz, fhqk, ssjb, cut_heal," +
|
|
|
- "(select top(1) yb_code from a_employee_mi where code = ssys) as oper_dr_code, " +
|
|
|
- "(select top(1) yb_code from a_employee_mi where code = mzys) as anst_dr_code," +
|
|
|
+ "(select top(1) rtrim(yb_code) from a_employee_mi where code = ssys) as oper_dr_code, " +
|
|
|
+ "(select top(1) rtrim(yb_code) from a_employee_mi where code = mzys) as anst_dr_code," +
|
|
|
"dept_code," +
|
|
|
"(select name from zd_unit_code where code = dept_code) as dept_code_name " +
|
|
|
"from ${tableName} left join zd_icd9_cm3 on (ssbm = zd_icd9_cm3.code) " +
|
|
|
@@ -549,14 +549,30 @@ public interface UpIdCollectionDao {
|
|
|
@Param("times") Integer times,
|
|
|
@Param("ledgerSn") Integer ledgerSn);
|
|
|
|
|
|
+ @Select("select icd_code_new as diag_code " +
|
|
|
+ "from mz_visit_table " +
|
|
|
+ "where nullif(icd_code_new, '') is not null " +
|
|
|
+ " and patient_id = #{patNo} and times = #{times}")
|
|
|
+ OpspdiseinfoUpld outpatientDiagnosis1(@Param("patNo") String patNo,
|
|
|
+ @Param("times") Integer times);
|
|
|
+
|
|
|
+ @Select("select yb_code as diag_code,\n" +
|
|
|
+ " yb_name as diag_name,\n" +
|
|
|
+ " '00000' as oprn_oprt_name,\n" +
|
|
|
+ " '无手术' as oprn_oprt_code\n" +
|
|
|
+ "from zd_icd_code_new\n" +
|
|
|
+ "where yb_code = #{ybCode} ")
|
|
|
+ OpspdiseinfoUpld outpatientSlowDiagnosis(String ybCode);
|
|
|
+
|
|
|
@Select("select diag_code as diag_code, " +
|
|
|
" diag_name as diag_name, " +
|
|
|
" '00000' as oprn_oprt_name, " +
|
|
|
" '无手术' as oprn_oprt_code " +
|
|
|
"from t_si_mz_diag\n" +
|
|
|
"where pat_no = #{patNo} and times = #{times} ")
|
|
|
- List<OpspdiseinfoUpld> outpatientDiagnosis(@Param("patNo") String patNo,
|
|
|
- @Param("times") Integer times);
|
|
|
+ List<OpspdiseinfoUpld> outpatientDiagnosis2(@Param("patNo") String patNo,
|
|
|
+ @Param("times") Integer times);
|
|
|
+
|
|
|
|
|
|
@Select("select top 1 rtrim(a.name) as psnName, " +
|
|
|
" isnull(nullif(rtrim(b.occupation_code), " +
|
|
|
@@ -604,6 +620,13 @@ public interface UpIdCollectionDao {
|
|
|
SetlinfoUpld mzPatInfo(@Param("patNo") String patNo,
|
|
|
@Param("times") Integer times);
|
|
|
|
|
|
+ @Select("select opsp_diag_caty = (select si_caty from zd_unit_code where code = visit_dept_code),\n" +
|
|
|
+ " visit_date as opsp_mdtrt_date\n" +
|
|
|
+ "from mz_visit_table\n" +
|
|
|
+ "where patient_id = #{patNo} and times = #{times}")
|
|
|
+ SetlinfoUpld mzPatInfo1(@Param("patNo") String patNo,
|
|
|
+ @Param("times") Integer times);
|
|
|
+
|
|
|
@Select("select setl_id,mdtrt_id,insuplc_admdvs " +
|
|
|
"from t_si_setlinfo " +
|
|
|
"where pat_no = #{patNo} " +
|