Forráskód Böngészése

修复报表统计里面查询不到门诊的历史。

xiaochan 3 éve
szülő
commit
4237af998f

+ 1 - 1
src/main/java/thyyxxk/webserver/dao/his/querydata/ConsumablesStatisticsDao.java

@@ -46,7 +46,7 @@ public interface ConsumablesStatisticsDao {
             "UNION ALL " +
             " select a.charge_item_code project_code,b.name entry_name,b.cl_code hospital_code,b.yb_comment origin_brand, " +
             "sum(quantity) number,sum(quantity*unit_price*drug_win) amount_of_money,source='门诊' " +
-            "from mz_charge_detail_b a,zd_charge_item b " +
+            "from mz_charge_detail a,zd_charge_item b " +
             "<where>" +
             "a.charge_item_code=b.code " +
             "<if test=\"startTime!='' and startTime!=null\"> " +

+ 4 - 5
src/main/java/thyyxxk/webserver/dao/his/querydata/QueryDrugsAndProjectsDao.java

@@ -63,7 +63,7 @@ public interface QueryDrugsAndProjectsDao {
             "union all " +
             "select a.charge_item_code chargeCode,b.name name,sum(a.quantity*drug_win) amount_of_money, " +
             "       sum(a.quantity*drug_win*unit_price) amountOfMoney, classCode=c.name,source='门诊' " +
-            "from mz_charge_detail_b a , zd_charge_item b , zd_charge_class c " +
+            "from mz_charge_detail a , zd_charge_item b , zd_charge_class c " +
             "where a.charge_item_code=b.code and b.class_code=c.code " +
             "<if test=\"startTime!=null and startTime!=''\">" +
             "and a.charge_date&gt;=#{startTime} and a.charge_date&lt;#{endTime} " +
@@ -133,7 +133,7 @@ public interface QueryDrugsAndProjectsDao {
             "    (select name from zd_unit_code where code = a.warn_dept) dept, " +
             "    (select name from zd_unit_code where code = a.exec_dept) exec_unit, " +
             "           yb_type = '自费',sum(a.quantity*a.drug_win) number,sum(a.quantity*drug_win*unit_price) amount_of_money,a.charge_item_code,source = '门诊' " +
-            "           from mz_charge_detail_b a,mz_patient_mi b " +
+            "           from mz_charge_detail a,mz_patient_mi b " +
             "where a.patient_id = b.patient_id " +
             "and a.times = b.times " +
             "and charge_item_code = #{chargeCode} " +
@@ -144,12 +144,11 @@ public interface QueryDrugsAndProjectsDao {
             "group by  charge_item_code,a.patient_id,a.times,b.name,social_no,phone_no,charge_date,exec_dept,a.warn_dept) temp GROUP BY " +
             "patient,times,name,social_no,phone,admiss_date,dis_date,charge_date,dept,exec_unit,yb_type,amount_of_money,number,charge_code,source" +
             "</script>")
-    // 如果不希望显示 0 的话 就去掉 amount_of_money 和 number
     List<QueryDrugsAndProjects> chaXunXiangMuHuoYaoPinJuTiXinXi(@Param("startTime") String startTime,
                                                                 @Param("endTime") String endTime,
                                                                 @Param("chargeCode") String chargeCode,
                                                                 @Param("dept") String dept);
-    
+
     /**
      * 查询药品
      *
@@ -182,7 +181,7 @@ public interface QueryDrugsAndProjectsDao {
             "select a.charge_item_code chargeCode," +
             "case a.serial when '01' then '药品(小)' when '99' then '药品(大)' end packageSpecification," +
             "b.name name,sum(a.quantity*drug_win) number,sum(a.quantity*drug_win*unit_price) amountOfMoney,source='门诊',classCode=c.name " +
-            "from mz_charge_detail_b a,yp_zd_dict b,yp_zd_drug_kind c " +
+            "from mz_charge_detail a,yp_zd_dict b,yp_zd_drug_kind c " +
             "where " +
             "1=1 " +
             "<if test=\"startTime!='' and startTime!=null\">" +

+ 1 - 1
src/main/java/thyyxxk/webserver/service/querydata/ConsumablesStatisticsService.java

@@ -38,7 +38,7 @@ public class ConsumablesStatisticsService {
     }
 
     /**
-     * 查询耗材使用统计  根据条件动态查询 这个sql语句太复杂了 mybatis-plus查询很慢
+     * 查询耗材使用统计  根据条件动态查询 这个sql语句太复杂了 mybatis-plus分页查询很慢
      *
      * @param param 条件 分页
      * @return 指定数据

+ 0 - 2
src/main/java/thyyxxk/webserver/service/zhuyuanyisheng/YiZhuLuRuServer.java

@@ -328,7 +328,6 @@ public class YiZhuLuRuServer {
         return ResultVoUtil.success(dao.huoQuZhiXinKeShi(StringUtil.isContainChinese(code)));
     }
 
-
     /**
      * 用来校验数据 以及插入医嘱和插入抗菌药物以及,插入医嘱模板
      *
@@ -881,5 +880,4 @@ public class YiZhuLuRuServer {
         return ResultVoUtil.success(ExceptionEnum.SUCCESS_AND_NOTIFICATION);
     }
 
-
 }