1.平台自动任务his处方信息汇总调整

develop/lyx_20241211_cfhz
lxx 4 weeks ago
parent 5399fbb39e
commit edc23aba23
  1. 73
      WEB-INF/conf/sysds_cfhz.xml
  2. 103
      WEB-INF/src/com/his/Cfhz/HisCfhzService.java
  3. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywCfsForm.xml
  4. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywInXyZjeForm.xml
  5. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywMainForm.xml
  6. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywQdForm.java
  7. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywQdForm.xml
  8. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/KjywSyrsForm.xml
  9. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/YfsrInAllForm.xml
  10. 2
      WEB-INF/src/com/openIntegratedQuery/kssquery/ZsjCfsForm.xml
  11. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/KjlypMxCountForm.xml
  12. 4
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/KssSyblCountForm.xml
  13. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/KssSylCountForm.java
  14. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/KssSylCountForm.xml
  15. 4
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/QyKssMxCountForm.java
  16. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/QyKssMxCountForm.xml
  17. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/TsYpCfCountForm.xml
  18. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/YsKjywHlyyCountForm.java
  19. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/YsKjywHlyyCountForm.xml
  20. 6
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/YsKssypSyCountForm.java
  21. 2
      WEB-INF/src/com/openIntegratedQuery/ygyyQuery/YsKssypSyCountForm.xml

@ -167,7 +167,9 @@
SFXMC,
XZKS,
ZXKS,
JGID
JGID,
ZDZBPKEY,
ZDMXPKEY
FROM
HIS_GAT_YPCF_MXB t
WHERE
@ -209,7 +211,8 @@
<f name="XZKS" type="12" table="HIS_GAT_YPCF_MXB" />
<f name="ZXKS" type="12" table="HIS_GAT_YPCF_MXB" />
<f name="JGID" type="12" table="HIS_GAT_YPCF_MXB" />
<!-- <f name="IS_YP" type="12" table="HIS_GAT_YPCF_MXB" /> -->
<f name="ZDZBPKEY" type="12" table="HIS_GAT_YPCF_MXB" />
<f name="ZDMXPKEY" type="12" table="HIS_GAT_YPCF_MXB" />
</fields>
</dao>
@ -362,7 +365,8 @@
c.MC AS YPMC,
b.YZSHRQ,
b.YZZXKS,
b.YZXZKS
b.YZXZKS,
zb.PKEY
FROM
HIS_SFZD_SFXMXB a
LEFT JOIN HIS_YZ_MXB b ON
@ -376,6 +380,9 @@
LEFT JOIN HIS_YZ_YPYF y ON
b.JGID = y.JGID
AND b.YZYF = y.BM
LEFT JOIN HIS_SFZD_ZB zb ON
a.JGID =zb.JGID
AND a.ZDZBPKEY =zb.PKEY
WHERE
a.JGID =?
AND a.JFRQ >=?
@ -415,6 +422,7 @@
<f name="YZSHRQ" type="93" />
<f name="YZZXKS" type="12" />
<f name="YZXZKS" type="12" />
<f name="PKEY" type="12" />
</fields>
<parameter>
<p>12</p>
@ -499,22 +507,55 @@
<dao id="cfhz_zd_dao" log="true" type="1">
<sql><![CDATA[
SELECT
DISTINCT yzmx.CFH ,
DISTINCT zb.CFH,
sfzb.pkey ZDPKEY,
zb.ZDZBPKEY,
zb.PKEY
hzmx.ZDZBPKEY,
hzmx.PKEY
FROM
HIS_SFZD_SFXMXB sfmx
LEFT JOIN HIS_YZ_MXB yzmx ON
sfmx.JGID = yzmx.JGID
AND SFMX.YZMX = yzmx.PKEY
HIS_GAT_YPCF_MXB hzmx
LEFT JOIN HIS_SFZD_SFXMXB sfmx ON
hzmx.JGID =sfmx.JGID AND hzmx.ZDMXPKEY =sfmx.PKEY
LEFT JOIN HIS_GAT_YPCF_ZB zb ON
yzmx.JGID = zb.JGID
AND yzmx.CFH = zb.CFH
hzmx.JGID = zb.JGID AND hzmx.ZBPKEY =zb.PKEY
LEFT JOIN HIS_SFZD_ZB sfzb ON sfmx.JGID =sfzb.JGID AND sfmx.ZDZBPKEY =sfzb.PKEY
WHERE
zb.ZDZBPKEY IS NULL
AND sfmx.ZDZBPKEY != '空'
hzmx.ZDZBPKEY IS NULL
AND sfzb.PKEY IS NOT NULL
AND hzmx.JGID =?
]]></sql>
<tables>
<table name="HIS_GAT_YPCF_MXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>ZDZBPKEY</primary>
</table>
</tables>
//CFH,PKEY,ZDZBPKEY
<fields>
<f name="CFH" type="12" />
<f name="ZDPKEY" type="12" />
<f name="ZDZBPKEY" type="12" table="HIS_GAT_YPCF_MXB" />
<f name="PKEY" type="12" table="HIS_GAT_YPCF_MXB" />
</fields>
<parameter>
<p>12</p>
</parameter>
</dao>
<dao id="cfhz_zdmx_dao" log="true" type="1">
<sql><![CDATA[
SELECT
DISTINCT zb.CFH,
hzmx.ZDZBPKEY MXZD,
zb.PKEY,
zb.ZDZBPKEY
FROM
HIS_GAT_YPCF_MXB hzmx
LEFT JOIN HIS_GAT_YPCF_ZB zb ON
hzmx.JGID = zb.JGID AND hzmx.ZBPKEY =zb.PKEY
WHERE
hzmx.ZDZBPKEY IS NOT NULL
AND zb.ZDZBPKEY IS NULL
AND zb.JGID =?
]]></sql>
<tables>
@ -526,9 +567,9 @@
//CFH,PKEY,ZDZBPKEY
<fields>
<f name="CFH" type="12" />
<f name="ZDPKEY" type="12" />
<f name="ZDZBPKEY" type="12" table="HIS_GAT_YPCF_ZB" />
<f name="MXZD" type="12" />
<f name="PKEY" type="12" table="HIS_GAT_YPCF_ZB" />
<f name="ZDZBPKEY" type="12" table="HIS_GAT_YPCF_ZB" />
</fields>
<parameter>
<p>12</p>

@ -136,7 +136,7 @@ public class HisCfhzService {
System.err.println(date0+"==="+CFH+"==="+JZLX+"==="+JJKS+"==="+YZXZYS);
//判断是否存在处方信息,否 新境,是 更新处方信息
int row=cfhz_ypcfzb_dao.find(new String[] {"CFRQ","CFH","JZLX","CFKS","CFYS"}, new String[] {date0,CFH,JZLX,JJKS,YZXZYS});
int row=cfhz_ypcfzb_dao.find(new String[] {"CFRQ","CFH","JZLX","CFKS","CFYS","ZDZBPKEY"}, new String[] {date0,CFH,JZLX,JJKS,YZXZYS,ZDZBPKEY});
if (row==-1) {
cfhz_ypcfzb_dao.absolute(cfhz_ypcfzb_dao.insert(cfhz_ypcfzb_dao.getRowCount()));
cfhz_ypcfzb_dao.setColumnValue("PKEY", SnowIdUtils.uniqueLong());
@ -307,6 +307,8 @@ public class HisCfhzService {
String SHRQ=MainUtil.format(cfmxdao.getColumnValueAsLong(i,"YZSHRQ"), "yyyyMMdd");//同一处方号,医嘱明细审核日期有同天但时间不相等数据
String XZKS=cfmxdao.getColumnValueAsString(i,"YZXZKS");
String ZXKS=cfmxdao.getColumnValueAsString(i,"YZZXKS");
String ZDZBPKEY=cfmxdao.getColumnValueAsString(i,"PKEY");
String ZDMXPKEY=cfmxdao.getColumnValueAsString(i,"SFPKEY");
if (Delphi.isNullString(CFH)) {
@ -359,8 +361,8 @@ public class HisCfhzService {
//String IS_YP="0";
//判断当前日期天内是否有处方药品,否 新增项,是 已有项金额叠加
if (mxmap.get(CFH+YZXPKEY)==null) {
mxmap.put(CFH+YZXPKEY, YZXPKEY);
// if (mxmap.get(CFH+YZXPKEY+ZDZBPKEY)==null) {
// mxmap.put(CFH+YZXPKEY+ZDZBPKEY, YZXPKEY);
if (!Delphi.isNullString(BM)) {
PZS=MathUtil.add(PZS, 1);
@ -422,45 +424,45 @@ public class HisCfhzService {
YF_JZ_PZS="1";
YF_JZ_JE=SFXZFY;
}
}else {
if (!Delphi.isNullString(BM)) {
PZS=MathUtil.add(PZS, 1);
//IS_YP="1";
CFYPJE=SFXZFY;
}
//是否基本药物
if ("1".equals(ISGJJBYW)) {
JY_JE=SFXZFY;
}
//管制分类
if("KSS1".equals(GZFL)) {
GZ_KSS1_JE=SFXZFY;
KSS1_BDD=BDD;
KSS1_DDD=DDD;
}else if ("KSS2".equals(GZFL)) {
GZ_KSS2_JE=SFXZFY;
KSS2_BDD=BDD;
KSS2_DDD=DDD;
}else if ("KSS3".equals(GZFL)) {
GZ_KSS3_JE=SFXZFY;
KSS3_BDD=BDD;
KSS3_DDD=DDD;
}else if ("J1".equals(GZFL)) {
GZ_J1_JE=SFXZFY;
}else if ("J2".equals(GZFL)) {
GZ_J2_JE=SFXZFY;
}else if ("MZ".equals(GZFL)) {
GZ_MZ_JE=SFXZFY;
}
//用法
if("1".equals(ISJMGY)) {
YF_SY_JE=SFXZFY;
}else if ("1".equals(ISZSGY)) {
YF_JZ_JE=SFXZFY;
}
}
// }else {
//
// if (!Delphi.isNullString(BM)) {
// PZS=MathUtil.add(PZS, 1);
// //IS_YP="1";
// CFYPJE=SFXZFY;
// }
//
// //是否基本药物
// if ("1".equals(ISGJJBYW)) {
// JY_JE=SFXZFY;
// }
// //管制分类
// if("KSS1".equals(GZFL)) {
// GZ_KSS1_JE=SFXZFY;
// KSS1_BDD=BDD;
// KSS1_DDD=DDD;
// }else if ("KSS2".equals(GZFL)) {
// GZ_KSS2_JE=SFXZFY;
// KSS2_BDD=BDD;
// KSS2_DDD=DDD;
// }else if ("KSS3".equals(GZFL)) {
// GZ_KSS3_JE=SFXZFY;
// KSS3_BDD=BDD;
// KSS3_DDD=DDD;
// }else if ("J1".equals(GZFL)) {
// GZ_J1_JE=SFXZFY;
// }else if ("J2".equals(GZFL)) {
// GZ_J2_JE=SFXZFY;
// }else if ("MZ".equals(GZFL)) {
// GZ_MZ_JE=SFXZFY;
// }
// //用法
// if("1".equals(ISJMGY)) {
// YF_SY_JE=SFXZFY;
// }else if ("1".equals(ISZSGY)) {
// YF_JZ_JE=SFXZFY;
// }
// }
//剂型大类(值:[MAIN_ZDB]的zdzb_bh='JXDL')
//01 口服剂
@ -481,7 +483,7 @@ public class HisCfhzService {
}
//定位处方信息汇总表
int row =cfhz_ypcfzb_dao.find("CFH",CFH);
int row=cfhz_ypcfzb_dao.find(new String[] {"CFH","ZDZBPKEY"}, new String[] {CFH,ZDZBPKEY});
cfhz_ypcfzb_dao.setColumnValue(row,"CFJE", MathUtil.add(cfhz_ypcfzb_dao.getColumnValueAsString(row,"CFJE"), SFXZFY));//处方金额 SUM(HIS_SFZD_SFXMXB.SFXZFY)
//判断是否抗菌处方 是 处方总金额写入抗菌处方金额
@ -551,7 +553,7 @@ public class HisCfhzService {
KSS2_DDD=MathUtil.add(KSS2_DDD, 0);
KSS3_DDD=MathUtil.add(KSS3_DDD, 0);
cfhz_ypcfmxb_dao.setColumnValue("KSS_DDDS", MathUtil.multiply(BDD, SFXSL));//使用抗生素 处方天数最高剂量限额 HIS_YPXX.DDD * YZTS
cfhz_ypcfmxb_dao.setColumnValue("KSS_DDDS", MathUtil.multiply(DDD, YZTS));//使用抗生素 处方天数最高剂量限额 HIS_YPXX.DDD * YZTS
cfhz_ypcfmxb_dao.setColumnValue("KSS1_BDD", KSS1_BDD);//非限制使用抗生素 基本单位剂量 HIS_YPXX.BDD
cfhz_ypcfmxb_dao.setColumnValue("KSS1_BDDS", MathUtil.multiply(KSS1_BDD, SFXSL));//非限制使用抗生素 基本单位总剂量 HIS_YPXX.BDD * JBDWSL
cfhz_ypcfmxb_dao.setColumnValue("KSS1_DDD", KSS1_DDD);//非限制使用抗生素 日最高剂量限额 HIS_YPXX.DDD
@ -568,8 +570,9 @@ public class HisCfhzService {
cfhz_ypcfmxb_dao.setColumnValue("XZKS", XZKS);//下嘱科室
cfhz_ypcfmxb_dao.setColumnValue("ZXKS", ZXKS);//执行科室
cfhz_ypcfmxb_dao.setColumnValue("JGID", companyId);//
//cfhz_ypcfmxb_dao.setColumnValue("IS_YP", IS_YP);//是否药品 0否 1是
cfhz_ypcfmxb_dao.setColumnValue("JGID", companyId);//
cfhz_ypcfmxb_dao.setColumnValue("ZDZBPKEY", ZDZBPKEY);//
cfhz_ypcfmxb_dao.setColumnValue("ZDMXPKEY", ZDMXPKEY);//收费明细PKEY
}
}
@ -588,6 +591,14 @@ public class HisCfhzService {
}
cfhz_zd_dao.commit();
DxNormalDataManager cfhz_zdmx_dao = DaoCreator.getNormalDao("cfhz_zdmx_dao");//收费账单信息
cfhz_zdmx_dao.reload(new Object[] {companyId});
for (int i = 0; i < cfhz_zdmx_dao.getRowCount(); i++) {
String ZDZBPKEY=cfhz_zdmx_dao.getColumnValueAsString(i,"MXZD");//收费主账单PKEY
cfhz_zdmx_dao.setColumnValue(i, "ZDZBPKEY",ZDZBPKEY);
}
cfhz_zdmx_dao.commit();
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -1 +1 @@
<?xml version="1.0" encoding="UTF-8"?> <window size="927,550" title="合理用药" controlbutton="false,false,true"> <DxTitlePanel id="titlePanel1" text-align="left" title="合理用药" size="100,100" unit="%,%"> <DxDataGrid id="dbgrid1" ds1="kssdao" size="100,100" unit="%,%" showfoot1="true" location="0,0" tabindex="0" > <column calc="true" fieldname="no" cellcolor="true" type="SERIALNUMBER_CELL" align="center" width="30">序号</column> <column fieldname="指标名称" width="300" sort="true" >指标名称</column> <column fieldname="指标数据" width="124" sort="true" >指标数据</column> </DxDataGrid> </DxTitlePanel> <datasource> <!-- <dao id="kjlypnum" type="1"> <sql> select distinct count(yzxpkey) num from (select distinct yzmxb.yzxpkey from HIS_YB_JSB a left join HIS_YB_DJ dj on a.JGID=dj.JGID and a.MDTRT_ID=dj.MDTRT_ID and a.IPT_NO=dj.IPT_NO left join HIS_YB_SCMX c on a.JGID=c.JGID and c.IPT_OTP_NO=a.IPT_NO and c.MDTRT_ID=a.MDTRT_ID and c.SETL_ID=a.SETL_ID left join HIS_SFZD_SFXMXB sfxmxb on c.FEEDETL_SN=sfxmxb.pkey and c.JGID=sfxmxb.JGID left join HIS_YZ_MXB yzmxb on sfxmxb.YZMX=yzmxb.pkey and sfxmxb.JGID=yzmxb.JGID right join HIS_YPXX ypxx on sfxmxb.sfx=ypxx.bm left join HIS_JZ_BASEINFO f on yzmxb.jzpkey=f.pkey and yzmxb.JGID=f.JGID left join HIS_HZINFO g on yzmxb.hzpkey=g.pkey and yzmxb.JGID=g.JGID where f.JZLX='M' and (yzmxb.yzlb ='01' or yzmxb.yzlb ='02' or yzmxb.yzlb ='03') and a.CXZT='0' and nvl(ypxx.ISKJY,0)=1 and a.JGID=? and f.jjrq between ? and ? ) </sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypnum" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY LEFT JOIN HIS_YB_JSB js ON zb.JGID = js.JGID AND zb.IPT_NO = js.IPT_NO WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' --AND js.CXZT = '0' AND zb.CFRQ >= ? AND zb.CFRQ <= ? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>12</p> <p>12</p> </parameter> </dao> <!-- <dao id="kjlypnum_jzrq" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY LEFT JOIN HIS_YB_JSB js ON zb.JGID = js.JGID AND zb.IPT_NO = js.IPT_NO WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' AND js.CXZT = '0' AND jz.jjrq >= ? AND jz.jjrq <= ? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypnum_sfrq" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY LEFT JOIN HIS_YB_JSB js ON zb.JGID = js.JGID AND zb.IPT_NO = js.IPT_NO WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' AND js.CXZT = '0' AND js.SETL_TIME >=? AND js.SETL_TIME <=? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> </datasource> </window>
<?xml version="1.0" encoding="UTF-8"?> <window size="927,550" title="合理用药" controlbutton="false,false,true"> <DxTitlePanel id="titlePanel1" text-align="left" title="合理用药" size="100,100" unit="%,%"> <DxDataGrid id="dbgrid1" ds1="kssdao" size="100,100" unit="%,%" showfoot1="true" location="0,0" tabindex="0" > <column calc="true" fieldname="no" cellcolor="true" type="SERIALNUMBER_CELL" align="center" width="30">序号</column> <column fieldname="指标名称" width="300" sort="true" >指标名称</column> <column fieldname="指标数据" width="124" sort="true" >指标数据</column> </DxDataGrid> </DxTitlePanel> <datasource> <!-- <dao id="kjlypnum" type="1"> <sql> select distinct count(yzxpkey) num from (select distinct yzmxb.yzxpkey from HIS_YB_JSB a left join HIS_YB_DJ dj on a.JGID=dj.JGID and a.MDTRT_ID=dj.MDTRT_ID and a.IPT_NO=dj.IPT_NO left join HIS_YB_SCMX c on a.JGID=c.JGID and c.IPT_OTP_NO=a.IPT_NO and c.MDTRT_ID=a.MDTRT_ID and c.SETL_ID=a.SETL_ID left join HIS_SFZD_SFXMXB sfxmxb on c.FEEDETL_SN=sfxmxb.pkey and c.JGID=sfxmxb.JGID left join HIS_YZ_MXB yzmxb on sfxmxb.YZMX=yzmxb.pkey and sfxmxb.JGID=yzmxb.JGID right join HIS_YPXX ypxx on sfxmxb.sfx=ypxx.bm left join HIS_JZ_BASEINFO f on yzmxb.jzpkey=f.pkey and yzmxb.JGID=f.JGID left join HIS_HZINFO g on yzmxb.hzpkey=g.pkey and yzmxb.JGID=g.JGID where f.JZLX='M' and (yzmxb.yzlb ='01' or yzmxb.yzlb ='02' or yzmxb.yzlb ='03') and a.CXZT='0' and nvl(ypxx.ISKJY,0)=1 and a.JGID=? and f.jjrq between ? and ? ) </sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypnum" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' AND zb.CFRQ >= ? AND zb.CFRQ <= ? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>12</p> <p>12</p> </parameter> </dao> <!-- <dao id="kjlypnum_jzrq" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY LEFT JOIN HIS_YB_JSB js ON zb.JGID = js.JGID AND zb.IPT_NO = js.IPT_NO WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' AND js.CXZT = '0' AND jz.jjrq >= ? AND jz.jjrq <= ? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypnum_sfrq" type="1"> <sql><![CDATA[ SELECT COUNT(1) num FROM ( SELECT DISTINCT mx.SFX FROM HIS_GAT_YPCF_MXB mx LEFT JOIN HIS_GAT_YPCF_ZB zb ON mx.ZBPKEY = zb.PKEY LEFT JOIN HIS_JZ_BASEINFO jz ON zb.JGID = jz.JGID AND zb.JZPKEY = jz.PKEY LEFT JOIN HIS_MZJS_MZFPZB fp ON zb.JGID = fp.JGID AND fp.GLZDBPKEY = zb.ZDZBPKEY WHERE zb.JGID = ? AND mx.GZFL LIKE 'KSS%' AND zb.CFLX = '0' AND fp.sfrq >=? AND fp.sfrq <=? ) ]]></sql> <fields> <f name="num" type="8" /> </fields> <parameter> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> </datasource> </window>

@ -4,7 +4,7 @@ package com.openIntegratedQuery.kssquery; import java.sql.Timestamp; import com
} public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/
/**/ DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); /* 系统自动生成,用于指定时间选择*/
/**/
} public void modalFunction(int flag, Object para) { if(flag == 110) { } } public void panelBar1selectAction(Timestamp bgtm,Timestamp edtm,String jzlx,DxNormalDataManager kssdao, String fsStr) { String companyid = MainUtil.getCurCompanyID(); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); String date0=MainUtil.format(bgtm, "yyyyMMdd"); String date1=MainUtil.format(edtm, "yyyyMMdd"); DxNormalDataManager zytjdao=DaoCreator.getNormalDao(this,"zytjdao"); zytjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); for(int i = 0;i < zytjdao.getRowCount();i++) { String num = zytjdao.getColumnValueAsString(i,"num"); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); fsStr,date0,date1,fsStr,bgtm,edtm}); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { fsStr,date0,date1,fsStr,bgtm,edtm}); String num = zytjdao.getColumnValueAsString(i,"num"); fsStr,date0,date1,fsStr,bgtm,edtm}); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); fsStr,date0,date1,fsStr,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); for(int i = 0;i < zytjdao.getRowCount();i++) { String num = zytjdao.getColumnValueAsString(i,"num"); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); fsStr,date0,date1,fsStr,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { if(dbgrid1.local("ks", jjks)) { dbgrid1.setColumnValue("DDD", MathUtil.add(dbgrid1.getColumnValue("ddd"), ddd)); fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); dbgrid1.reload(); for(int i = 0;i < dbgrid1.getRowCount();i++) { String ddd = dbgrid1.getColumnValueAsString(i,"ddd"); String crs = dbgrid1.getColumnValueAsString(i,"crs"); String qd = MathUtil.multiply(MathUtil.round(MathUtil.divide(ddd, crs),2),"100"); dbgrid1.setColumnValue(i,"qd", qd+"%"); } String zjddd = dbgrid1.getSumColumnValue("ddd"); String zjcrs = dbgrid1.getSumColumnValue("crs"); String zjqd = MathUtil.multiply(MathUtil.round(MathUtil.divide(zjddd, zjcrs),2),"100")+"%"; dbgrid1.setFootText("qd", zjqd); dbgrid1.absolute(0); if(kssdao.local("指标名称", "抗菌药物使用强度")) { kssdao.setColumnValue("指标数据", zjqd); } }
} public void modalFunction(int flag, Object para) { if(flag == 110) { } } public void panelBar1selectAction(Timestamp bgtm,Timestamp edtm,String jzlx,DxNormalDataManager kssdao, String fsStr) { String companyid = MainUtil.getCurCompanyID(); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); String date0=MainUtil.format(bgtm, "yyyyMMdd"); String date1=MainUtil.format(edtm, "yyyyMMdd"); DxNormalDataManager zytjdao=DaoCreator.getNormalDao(this,"zytjdao"); zytjdao.reload(new Object[]{companyid,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { String num = zytjdao.getColumnValueAsString(i,"num"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); String num = zytjdao.getColumnValueAsString(i,"num"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); fsStr,date0,date1,fsStr,bgtm,edtm}); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); for(int i = 0;i < zytjdao.getRowCount();i++) { String num = zytjdao.getColumnValueAsString(i,"num"); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); dbgrid1.reload(); dbgrid1.reload(); fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); dbgrid1.reload(); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); dbgrid1.reload(); zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); dbgrid1.reload(); dbgrid1.reload(); dbgrid1.reload(); dbgrid1.reload(); for(int i = 0;i < zytjdao.getRowCount();i++) { dbgrid1.reload(); String num = zytjdao.getColumnValueAsString(i,"num"); dbgrid1.reload(); String jjks = zytjdao.getColumnValueAsString(i,"jjks"); for(int i = 0;i < zytjdao.getRowCount();i++) { for(int i = 0;i < zytjdao.getRowCount();i++) { fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { for(int i = 0;i < zytjdao.getRowCount();i++) { DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); for(int i = 0;i < zytjdao.getRowCount();i++) { zyksstjdao.reload(new Object[]{companyid,fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { fsStr,date0,date1,fsStr,bgtm,edtm}); for(int i = 0;i < zytjdao.getRowCount();i++) { String ddd = MathUtil.multiply(SFXSL, ypbdd); ddd=MathUtil.divide(ddd, ypddd); ddd=MathUtil.round(ddd,2); if(dbgrid1.local("ks", jjks)) { for(int i = 0;i < zytjdao.getRowCount();i++) { String jjks = zytjdao.getColumnValueAsString(i,"jjks"); DxNormalDataManager zyksstjdao=DaoCreator.getNormalDao(this,"zyksstjdao"); } System.err.println(str); for(int i = 0;i < dbgrid1.getRowCount();i++) { String ddd = dbgrid1.getColumnValueAsString(i,"ddd"); String crs = dbgrid1.getColumnValueAsString(i,"crs"); String qd = MathUtil.multiply(MathUtil.round(MathUtil.divide(ddd, crs),2),"100"); dbgrid1.setColumnValue(i,"qd", qd+"%"); } String zjddd = dbgrid1.getSumColumnValue("ddd"); String zjcrs = dbgrid1.getSumColumnValue("crs"); String zjqd = MathUtil.multiply(MathUtil.round(MathUtil.divide(zjddd, zjcrs),2),"100")+"%"; dbgrid1.setFootText("qd", zjqd); dbgrid1.absolute(0); if(kssdao.local("指标名称", "抗菌药物使用强度")) { kssdao.setColumnValue("指标数据", zjqd); } }
private void panelBar1resetAction() { }
public void panelBar2exportAction(Timestamp bgtm,Timestamp edtm) { String title=Delphi.getDateStr(bgtm.getTime())+"至"+Delphi.getDateStr(edtm.getTime()); title+="抗菌药物处方数比例"; dbgrid1.exportExcelByXls(title); }

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -15,7 +15,7 @@ package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import co
private DxComboBox combobox1;
private DxComboBox combobox2; private DxComboBox combobox3; private DxDataGrid dbgrid2; public KssSylCountForm() { super(); } public static KssSylCountForm newWindow() { return (KssSylCountForm) WatForm.newWindow(KssSylCountForm.class.getName()); } public void initUI() { super.initUI(); customerInitUI(); } public void customerInitUI() { super.customerInitUI();
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "MZ"); combobox2.addItem("住院", "ZY"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "M"); combobox2.addItem("住院", "Z"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
/**/ combobox2.setSelectedIndex(0); combobox3.setSelectedIndex(0); DxNormalDataManager yltManagerHosDao = DaoCreator.getNormalDao(this,"yltManagerHosDao"); yltManagerHosDao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); yltManagerHosDao.reload(); dblookupcombobox1.addItem(MainUtil.getCurCompanyName(), MainUtil.getCurCompanyID()); dblookupcombobox1.addItems(yltManagerHosDao, "JGMC", "PKEY"); dblookupcombobox1.setSelectedIndex(0); dblookupcombobox1Action();
/* 系统自动生成,用于指定时间选择*/
combobox1.setSelectedIndex(0); changetime(); /**/

File diff suppressed because one or more lines are too long

@ -1,4 +1,4 @@
package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import com.util.MainUtil; import com.wat.component.DxComboBox; import com.wat.component.DxDateTimePick; import com.wat.component.DxLabel; import com.wat.component.DxPanelBar; import com.wat.component.DxPopGridText; import com.wat.component.datagrid.DxDataGrid; import com.wat.core.component.WatForm; import com.wat.core.component.WatWebForm; import com.wat.core.component.event.ActionEvent; import com.wat.core.component.event.ActionListener; import com.wat.core.component.event.WindowAdapter; import com.wat.core.component.event.WindowEvent; import com.wat.core.config.DaoCreator; import com.wat.core.dal.DxDataManager; import com.wat.core.dal.DxNormalDataManager; import com.wat.delphi.util.Delphi; public class QyKssMxCountForm extends WatWebForm { private DxDateTimePick datetimepicker1;
package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import com.util.MainUtil; import com.wat.component.DxComboBox; import com.wat.component.DxDateTimePick; import com.wat.component.DxLabel; import com.wat.component.DxPanelBar; import com.wat.component.DxPopGridText; import com.wat.component.datagrid.DxDataGrid; import com.wat.core.component.WatForm; import com.wat.core.component.WatWebForm; import com.wat.core.component.event.ActionEvent; import com.wat.core.component.event.ActionListener; import com.wat.core.component.event.WindowAdapter; import com.wat.core.component.event.WindowEvent; import com.wat.core.config.DaoCreator; import com.wat.core.dal.DxDataManager; import com.wat.core.dal.DxNormalDataManager; import com.wat.core.util.MathUtil; import com.wat.delphi.util.Delphi; public class QyKssMxCountForm extends WatWebForm { private DxDateTimePick datetimepicker1;
private DxDateTimePick datetimepicker2;
private DxDataGrid dbgrid1;
private DxPopGridText popgrid1;
@ -24,7 +24,7 @@ package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import co
}else if("reset".equals(command)) {
panelBar2resetAction();
}else if("export".equals(command)) { panelBar2exportAction(); } } private void panelBar2exportAction() { String jzlx=""+combobox2.getText(combobox2.getSelectedIndex()); dbgrid1.exportExcelByXls(Delphi.getDateTimeStr(datetimepicker1.getTime())+"至"+Delphi.getDateTimeStr(datetimepicker2.getTime())+"全院抗生素药品统计表"); }
private void panelBar2selectAction() { String companyid = ""; if(dblookupcombobox1.getSelectedIndex() >= 0) { companyid = dblookupcombobox1.getSelectedItem().getValue().toString(); } String jzlx=""+combobox2.getValue(combobox2.getSelectedIndex()); String ks=popgrid1.getValue(); if (Delphi.isNullString(ks)) { ks="%"; } String date0=MainUtil.format(datetimepicker1.getDate(), "yyyyMMdd"); String date1=MainUtil.format(datetimepicker2.getDate(), "yyyyMMdd"); if (combobox3.getSelectedIndex()==0) { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew")); dbgrid1.setParameters(new Object[]{companyid,jzlx,date0,date1,ks}); dbgrid1.reload(); }else { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew_sfrq")); dbgrid1.setParameters(new Object[]{companyid,jzlx,datetimepicker1.getTimeStamp(),datetimepicker2.getTimeStamp(),ks}); dbgrid1.reload(); } }
private void panelBar2selectAction() { String companyid = ""; if(dblookupcombobox1.getSelectedIndex() >= 0) { companyid = dblookupcombobox1.getSelectedItem().getValue().toString(); } String jzlx=""+combobox2.getValue(combobox2.getSelectedIndex()); String ks=popgrid1.getValue(); if (Delphi.isNullString(ks)) { ks="%"; } String date0=MainUtil.format(datetimepicker1.getDate(), "yyyyMMdd"); String date1=MainUtil.format(datetimepicker2.getDate(), "yyyyMMdd"); if (combobox3.getSelectedIndex()==0) { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew")); dbgrid1.setParameters(new Object[]{companyid,jzlx,date0,date1,ks}); dbgrid1.reload(); }else { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew_sfrq")); dbgrid1.setParameters(new Object[]{companyid,jzlx,datetimepicker1.getTimeStamp(),datetimepicker2.getTimeStamp(),ks}); dbgrid1.reload(); } for (int i = 0; i < dbgrid1.getRowCount(); i++) { String DDD=dbgrid1.getColumnValueAsString(i,"DDD"); String BDD=dbgrid1.getColumnValueAsString(i,"BDD"); String YZSL=dbgrid1.getColumnValueAsString(i,"YZSL"); dbgrid1.setColumnValue(i, "DDDs",Delphi.format("0.00",MathUtil.divide(MathUtil.multiply(YZSL, BDD), DDD))); } }
private void panelBar2resetAction() { popgrid1.setText("");
popgrid1.setValue("");

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -14,7 +14,7 @@ package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import co
private DxComboBox combobox1;
private DxComboBox combobox2; private DxComboBox combobox3; public YsKjywHlyyCountForm() { super(); } public static YsKjywHlyyCountForm newWindow() { return (YsKjywHlyyCountForm) WatForm.newWindow(YsKjywHlyyCountForm.class.getName()); } public void initUI() { super.initUI(); customerInitUI(); } public void customerInitUI() { super.customerInitUI();
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "0"); combobox2.addItem("住院", "1"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "M"); combobox2.addItem("住院", "Z"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
/**/ combobox2.setSelectedIndex(0); combobox3.setSelectedIndex(0); DxNormalDataManager yltManagerHosDao = DaoCreator.getNormalDao(this,"yltManagerHosDao"); yltManagerHosDao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); yltManagerHosDao.reload(); dblookupcombobox1.addItem(MainUtil.getCurCompanyName(), MainUtil.getCurCompanyID()); dblookupcombobox1.addItems(yltManagerHosDao, "JGMC", "PKEY"); dblookupcombobox1.setSelectedIndex(0); dblookupcombobox1Action();
/* 系统自动生成,用于指定时间选择*/
combobox1.setSelectedIndex(0); changetime(); /**/

File diff suppressed because one or more lines are too long

@ -1,4 +1,4 @@
package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import com.util.MainUtil; import com.wat.component.DxComboBox; import com.wat.component.DxDateTimePick; import com.wat.component.DxLabel; import com.wat.component.DxPanelBar; import com.wat.component.datagrid.DxDataGrid; import com.wat.core.component.WatForm; import com.wat.core.component.WatWebForm; import com.wat.core.component.event.ActionEvent; import com.wat.core.component.event.ActionListener; import com.wat.core.component.event.WindowAdapter; import com.wat.core.component.event.WindowEvent; import com.wat.core.config.DaoCreator; import com.wat.core.dal.DxNormalDataManager; import com.wat.delphi.util.Delphi; public class YsKssypSyCountForm extends WatWebForm { private DxDateTimePick datetimepicker1;
package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import com.util.MainUtil; import com.wat.component.DxComboBox; import com.wat.component.DxDateTimePick; import com.wat.component.DxLabel; import com.wat.component.DxPanelBar; import com.wat.component.datagrid.DxDataGrid; import com.wat.core.component.WatForm; import com.wat.core.component.WatWebForm; import com.wat.core.component.event.ActionEvent; import com.wat.core.component.event.ActionListener; import com.wat.core.component.event.WindowAdapter; import com.wat.core.component.event.WindowEvent; import com.wat.core.config.DaoCreator; import com.wat.core.dal.DxNormalDataManager; import com.wat.core.util.MathUtil; import com.wat.delphi.util.Delphi; public class YsKssypSyCountForm extends WatWebForm { private DxDateTimePick datetimepicker1;
private DxDateTimePick datetimepicker2;
private DxDataGrid dbgrid1;
private DxPanelBar panelBar1;
@ -14,7 +14,7 @@ package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import co
private DxComboBox combobox1;
private DxComboBox combobox2; private DxComboBox combobox3; public YsKssypSyCountForm() { super(); } public static YsKssypSyCountForm newWindow() { return (YsKssypSyCountForm) WatForm.newWindow(YsKssypSyCountForm.class.getName()); } public void initUI() { super.initUI(); customerInitUI(); } public void customerInitUI() { super.customerInitUI();
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "MZ"); combobox2.addItem("住院", "ZY"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
combobox1.addItem("统计今天", "1"); combobox1.addItem("统计昨天", "2"); combobox1.addItem("统计上月", "3"); combobox1.addItem("统计本月", "4"); combobox1.addItem("统计本年", "5"); combobox1.addItem("统计上午", "6"); combobox1.addItem("统计下午", "7"); combobox1.addItem("统计晚上", "8"); combobox2.addItem("全部", "%"); combobox2.addItem("门诊", "M"); combobox2.addItem("住院", "Z"); combobox3.addItem("按计费时间", "0"); combobox3.addItem("按收费时间", "1"); } public void beforeShowLoad() { super.beforeShowLoad(); /* 系统自动生成,用于lds和dic中的需要参数的dao的初始化装载数据,默认参数填入机构参数,请根据实际情况修改参数*/ //费用大类 DxNormalDataManager hisfydldao=DaoCreator.getNormalDao(this,"hisfydldao"); hisfydldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfydldao.reloadByDictionary("MC", "BH"); //费用子类 DxNormalDataManager hisfyzldao=DaoCreator.getNormalDao(this,"hisfyzldao"); hisfyzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hisfyzldao.reloadByDictionary("MC", "BH"); //核算子分类 DxNormalDataManager hishszldao=DaoCreator.getNormalDao(this,"hishszldao"); hishszldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hishszldao.reloadByDictionary("MC", "BH"); //会计子分类 DxNormalDataManager hiskjzldao=DaoCreator.getNormalDao(this,"hiskjzldao"); hiskjzldao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); hiskjzldao.reloadByDictionary("MC", "BH"); //病案首页分类 DxNormalDataManager basyfldao=DaoCreator.getNormalDao(this,"basyfldao"); basyfldao.reloadByDictionary("MC", "BH"); DxNormalDataManager jylxdic = DaoCreator.getNormalDao(this,"jylxdic"); jylxdic.reloadByDictionary("MC", "BH"); DxNormalDataManager jgrydicdao = DaoCreator.getNormalDao(this,"jgrydicdao"); jgrydicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); jgrydicdao.reloadByDictionary("NAME", "USERACCOUNT"); DxNormalDataManager dpdicdao = DaoCreator.getNormalDao(this,"dpdicdao"); dpdicdao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); dpdicdao.reloadByDictionary("DPTNAME", "DPTID"); DxNormalDataManager dwdicdao = DaoCreator.getNormalDao(this,"dwdicdao"); dwdicdao.reloadByDictionary("MC", "BH");
/**/ combobox2.setSelectedIndex(0); combobox3.setSelectedIndex(0); DxNormalDataManager yltManagerHosDao = DaoCreator.getNormalDao(this,"yltManagerHosDao"); yltManagerHosDao.setNormalParameters(new Object[]{MainUtil.getCurCompanyID()}); yltManagerHosDao.reload(); dblookupcombobox1.addItem(MainUtil.getCurCompanyName(), MainUtil.getCurCompanyID()); dblookupcombobox1.addItems(yltManagerHosDao, "JGMC", "PKEY"); dblookupcombobox1.setSelectedIndex(0); dblookupcombobox1Action();
/* 系统自动生成,用于指定时间选择*/
combobox1.setSelectedIndex(0); changetime(); /**/
@ -23,7 +23,7 @@ package com.openIntegratedQuery.ygyyQuery; import java.util.Calendar; import co
}else if("reset".equals(command)) {
panelBar2resetAction();
}else if("export".equals(command)) { panelBar2exportAction(); } } private void panelBar2exportAction() { String jzlx=""+combobox2.getText(combobox2.getSelectedIndex()); dbgrid1.exportExcelByXls(jzlx+"医生抗生素药品使用况表",Delphi.getDateTimeStr(datetimepicker1.getTime())+"至"+Delphi.getDateTimeStr(datetimepicker2.getTime())); }
private void panelBar2selectAction() { String companyid = ""; if(dblookupcombobox1.getSelectedIndex() >= 0) { companyid = dblookupcombobox1.getSelectedItem().getValue().toString(); } String jzlx=""+combobox2.getValue(combobox2.getSelectedIndex()); String date0=MainUtil.format(datetimepicker1.getDate(), "yyyyMMdd"); String date1=MainUtil.format(datetimepicker2.getDate(), "yyyyMMdd"); if (combobox3.getSelectedIndex()==0) { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew")); dbgrid1.setParameters(new Object[]{companyid,jzlx,date0,date1}); dbgrid1.reload(); }else { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew_sfrq")); dbgrid1.setParameters(new Object[]{companyid,jzlx,datetimepicker1.getTimeStamp(),datetimepicker2.getTimeStamp()}); dbgrid1.reload(); } }
private void panelBar2selectAction() { String companyid = ""; if(dblookupcombobox1.getSelectedIndex() >= 0) { companyid = dblookupcombobox1.getSelectedItem().getValue().toString(); } String jzlx=""+combobox2.getValue(combobox2.getSelectedIndex()); String date0=MainUtil.format(datetimepicker1.getDate(), "yyyyMMdd"); String date1=MainUtil.format(datetimepicker2.getDate(), "yyyyMMdd"); if (combobox3.getSelectedIndex()==0) { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew")); dbgrid1.setParameters(new Object[]{companyid,jzlx,date0,date1}); dbgrid1.reload(); }else { dbgrid1.setDataObjectManager( DaoCreator.getNormalDao(this, "kjlypMxDaoNew_sfrq")); dbgrid1.setParameters(new Object[]{companyid,jzlx,datetimepicker1.getTimeStamp(),datetimepicker2.getTimeStamp()}); dbgrid1.reload(); } for (int i = 0; i < dbgrid1.getRowCount(); i++) { String DDD=dbgrid1.getColumnValueAsString(i,"DDD值"); String DDDs=dbgrid1.getColumnValueAsString(i,"DDDs"); dbgrid1.setColumnValue(i, "DDDs",Delphi.format("0.00",MathUtil.divide(DDDs, DDD))); } }
private void panelBar2resetAction() { combobox1.setSelectedIndex(0); }

@ -1,3 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?> <window size="927,550" title="医生抗生素药品使用统计" controlbutton="false,false,true"> <DxDIVGrid bkcolor="255,255,255" class="LayoutManager" location="0,0" size="100,100" unit="%,%"> <row height="40" unit="px"> <col> <DxPanelBar id="panelBar1" border-bottom="1px solid #b8ced7" border-top="1px solid #b8ced7" size="100,38" unit="%"> <item align="left" autoExtend="false"> <DxLabel id="label1" size="60,13" title="常用时段" /> <DxComboBox id="combobox1" size="140,28" /> </item> <item align="left" autoExtend="false"> <DxLabel id="label2" size="60,13" title="开始日期" /> <DxDateTimePick id="datetimepicker1" size="140,28" type="datetime" /> </item> <item align="left" autoExtend="false"> <DxLabel id="label3" size="60,13" title="结束日期" /> <DxDateTimePick id="datetimepicker2" size="140,28" type="datetime" /> </item> <item align="left" autoExtend="false"> <DxLabel id="label4" size="35,13" title="医院" /> <DxComboBox id="dblookupcombobox1" size="140,28" /> </item> </DxPanelBar> </col> </row> <row height="40" unit="px"> <col> <DxPanelBar id="panelBar2" size="100,38" unit="%"> <item align="left"> <DxLabel id="label4" size="96,13" title="类型" /> <DxComboBox id="combobox2" size="80,28" /> </item> <item align="left"> <DxLabel id="label4" size="96,13" title="方式"/> <DxComboBox id="combobox3" size="100,28" /> </item> <item align="left" command="select" image="/resources/normal/query.png" title="查询" type="button" /> <item align="left" command="reset" image="/resources/normal/reset.png" title="重置" type="button" /> <item align="left" command="export" image="/resources/normal/export.png" color="#ffffff" bkcolor="#009688" title="导出" type="button" /> </DxPanelBar> </col> </row> <row height="99"> <col> <DxDataGrid ds="kjlypMxDaoNew" id="dbgrid1" showfoot="true" size="100,100" unit="%,%"> <column fieldname="医生" type="LABEL_CELL" footexp="合计" width="120">下嘱医生</column> <column fieldname="药品名称" type="LABEL_CELL" width="200">药品名称</column> <column fieldname="规格" type="LABEL_CELL" width="200">规格</column> <column fieldname="数量" type="LABEL_CELL" footexp="$sum(数量)" width="120" align="right">数量</column> <column fieldname="金额" type="LABEL_CELL" footexp="$sum(金额)" width="120" align="right">金额</column> <column fieldname="等效数量" type="LABEL_CELL" width="120" align="right">等效数量</column> <column fieldname="DDD值" type="LABEL_CELL" width="120" align="right">DDD值</column> <column fieldname="DDDs" type="LABEL_CELL" footexp="$sum(DDDs)" width="120" align="right">DDDs</column> <column fieldname="" calc="true" type="LABEL_CELL"></column> </DxDataGrid> </col> </row> </DxDIVGrid> <dxselectcontroler id="s1">
<s ctrid="popgrid1" col="YZXZKS" ctrtype="DxPopGridText" coltype="12" isvalue="true" bjgx="=" />
</dxselectcontroler> <datasource> <!-- <dao id="kjlypMxDao" log="true" type="1"> <sql><![CDATA[ select y.name 医生,yzmxb.yzmc 药品名称,ypxx.GG 规格,ypxx.DXSL as 等效数量,sum(sfxmxb.SFXSL) as 数量,sum(sfxmxb.SFXZFY) as 金额,min(ypxx.DDD) as DDD值,trunc(sum(sfxmxb.SFXSL*ypxx.DXSL/nvl(ypxx.DDD,1)),2) as DDDs from HIS_YB_JSB a left join HIS_YB_DJ dj on a.JGID=dj.JGID and a.MDTRT_ID=dj.MDTRT_ID and a.IPT_NO=dj.IPT_NO left join HIS_YB_SCMX c on a.JGID=c.JGID and c.IPT_OTP_NO=a.IPT_NO and c.MDTRT_ID=a.MDTRT_ID and c.SETL_ID=a.SETL_ID left join HIS_SFZD_SFXMXB sfxmxb on c.FEEDETL_SN=sfxmxb.pkey and c.JGID=sfxmxb.JGID left join HIS_YZ_MXB yzmxb on sfxmxb.YZMX=yzmxb.pkey and sfxmxb.JGID=yzmxb.JGID left join HIS_YPXX ypxx on sfxmxb.sfx=ypxx.bm left join HIS_JZ_BASEINFO f on yzmxb.jzpkey=f.pkey and yzmxb.JGID=f.JGID left join HIS_HZINFO g on yzmxb.hzpkey=g.pkey and yzmxb.JGID=g.JGID left join MAIN_YHXX y ON yzmxb.YZXZYS=y.USERACCOUNT left join MAIN_KS ks ON yzmxb.jgid=ks.jgid AND ks.DPTID=yzmxb.YZXZKS where (yzmxb.yzlb ='01' or yzmxb.yzlb ='02' or yzmxb.yzlb ='03') and a.CXZT='0' AND nvl(ypxx.ISKJY,0)=1 and a.JGID=? and a.JZLX like ? and a.SETL_TIME between ? and ? group by y.name,yzmxb.yzmc,ypxx.GG,ypxx.DXSL ]]></sql> <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="12" /> <f name="数量" type="12" /> <f name="金额" type="12" /> <f name="DDD值" type="12" /> <f name="DDDs" type="12" /> </fields> <parameter> <p>12</p> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypMxDaoNew" log="true" type="1"> <sql><![CDATA[ SELECT b.CFYS 医生, a.SFXMC 药品名称, yp.GG 规格, yp.DXSL 等效数量, SUM(a.SFXSL) 数量, SUM(a.SFXZJE) 金额, yp.DDD DDD值, SUM(a.KSS_DDDS) DDDs FROM HIS_GAT_YPCF_MXB a LEFT JOIN HIS_YPXX yp ON a.SFX = yp.BM LEFT JOIN HIS_GAT_YPCF_ZB b ON a.ZBPKEY = b.PKEY WHERE b.JGID =? AND b.JZLX like ? AND b.CFRQ >=? AND b.CFRQ <=? AND a.GZFL LIKE 'KSS%' GROUP BY b.CFYS, a.SFXMC, yp.GG, yp.DXSL, yp.DDD ]]></sql> //医生,药品名称,规格,等效数量,数量,金额,DDD值,DDDS <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="8" /> <f name="数量" type="4" /> <f name="金额" type="4" /> <f name="DDD值" type="8" /> <f name="DDDS" type="4" /> </fields> <parameter> <p>12</p> <p>12</p> <p>12</p> <p>12</p> </parameter> </dao> <dao id="kjlypMxDaoNew_sfrq" log="true" type="1"> <sql><![CDATA[ SELECT b.CFYS 医生, a.SFXMC 药品名称, yp.GG 规格, yp.DXSL 等效数量, SUM(a.SFXSL) 数量, SUM(a.SFXZJE) 金额, yp.DDD DDD值, SUM(a.KSS_DDDS) DDDs FROM HIS_GAT_YPCF_MXB a LEFT JOIN HIS_YPXX yp ON a.SFX = yp.BM LEFT JOIN HIS_GAT_YPCF_ZB b ON a.ZBPKEY = b.PKEY LEFT JOIN HIS_YB_JSB js ON b.JGID =js.JGID AND b.IPT_NO =js.IPT_NO AND js.CXZT ='0' WHERE b.JGID =? AND b.JZLX like ? AND js.SETL_TIME >=? AND js.SETL_TIME <=? AND a.GZFL LIKE 'KSS%' GROUP BY b.CFYS, a.SFXMC, yp.GG, yp.DXSL, yp.DDD ]]></sql> //医生,药品名称,规格,等效数量,数量,金额,DDD值,DDDS <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="8" /> <f name="数量" type="4" /> <f name="金额" type="4" /> <f name="DDD值" type="8" /> <f name="DDDS" type="4" /> </fields> <parameter> <p>12</p> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> </datasource> </window>
</dxselectcontroler> <datasource> <!-- <dao id="kjlypMxDao" log="true" type="1"> <sql><![CDATA[ select y.name 医生,yzmxb.yzmc 药品名称,ypxx.GG 规格,ypxx.DXSL as 等效数量,sum(sfxmxb.SFXSL) as 数量,sum(sfxmxb.SFXZFY) as 金额,min(ypxx.DDD) as DDD值,trunc(sum(sfxmxb.SFXSL*ypxx.DXSL/nvl(ypxx.DDD,1)),2) as DDDs from HIS_YB_JSB a left join HIS_YB_DJ dj on a.JGID=dj.JGID and a.MDTRT_ID=dj.MDTRT_ID and a.IPT_NO=dj.IPT_NO left join HIS_YB_SCMX c on a.JGID=c.JGID and c.IPT_OTP_NO=a.IPT_NO and c.MDTRT_ID=a.MDTRT_ID and c.SETL_ID=a.SETL_ID left join HIS_SFZD_SFXMXB sfxmxb on c.FEEDETL_SN=sfxmxb.pkey and c.JGID=sfxmxb.JGID left join HIS_YZ_MXB yzmxb on sfxmxb.YZMX=yzmxb.pkey and sfxmxb.JGID=yzmxb.JGID left join HIS_YPXX ypxx on sfxmxb.sfx=ypxx.bm left join HIS_JZ_BASEINFO f on yzmxb.jzpkey=f.pkey and yzmxb.JGID=f.JGID left join HIS_HZINFO g on yzmxb.hzpkey=g.pkey and yzmxb.JGID=g.JGID left join MAIN_YHXX y ON yzmxb.YZXZYS=y.USERACCOUNT left join MAIN_KS ks ON yzmxb.jgid=ks.jgid AND ks.DPTID=yzmxb.YZXZKS where (yzmxb.yzlb ='01' or yzmxb.yzlb ='02' or yzmxb.yzlb ='03') and a.CXZT='0' AND nvl(ypxx.ISKJY,0)=1 and a.JGID=? and a.JZLX like ? and a.SETL_TIME between ? and ? group by y.name,yzmxb.yzmc,ypxx.GG,ypxx.DXSL ]]></sql> <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="12" /> <f name="数量" type="12" /> <f name="金额" type="12" /> <f name="DDD值" type="12" /> <f name="DDDs" type="12" /> </fields> <parameter> <p>12</p> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> --> <dao id="kjlypMxDaoNew" log="true" type="1"> <sql><![CDATA[ SELECT b.CFYS 医生, a.SFXMC 药品名称, yp.GG 规格, yp.DXSL 等效数量, SUM(a.SFXSL) 数量, SUM(a.SFXZJE) 金额, yp.DDD DDD值, SUM(a.KSS_DDDS) DDDs FROM HIS_GAT_YPCF_MXB a LEFT JOIN HIS_YPXX yp ON a.SFX = yp.BM LEFT JOIN HIS_GAT_YPCF_ZB b ON a.ZBPKEY = b.PKEY WHERE b.JGID =? AND b.JZLX like ? AND b.CFRQ >=? AND b.CFRQ <=? AND a.GZFL LIKE 'KSS%' GROUP BY b.CFYS, a.SFXMC, yp.GG, yp.DXSL, yp.DDD ]]></sql> //医生,药品名称,规格,等效数量,数量,金额,DDD值,DDDS <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="8" /> <f name="数量" type="4" /> <f name="金额" type="4" /> <f name="DDD值" type="8" /> <f name="DDDS" type="4" /> </fields> <parameter> <p>12</p> <p>12</p> <p>12</p> <p>12</p> </parameter> </dao> <dao id="kjlypMxDaoNew_sfrq" log="true" type="1"> <sql><![CDATA[ SELECT b.CFYS 医生, a.SFXMC 药品名称, yp.GG 规格, yp.DXSL 等效数量, SUM(a.SFXSL) 数量, SUM(a.SFXZJE) 金额, yp.DDD DDD值, SUM(a.KSS_DDDS) DDDs FROM HIS_GAT_YPCF_MXB a LEFT JOIN HIS_YPXX yp ON a.SFX = yp.BM LEFT JOIN HIS_GAT_YPCF_ZB b ON a.ZBPKEY = b.PKEY LEFT JOIN HIS_MZJS_MZFPZB fp ON b.JGID = fp.JGID AND fp.GLZDBPKEY = b.ZDZBPKEY WHERE b.JGID =? AND b.JZLX like ? AND fp.sfrq >=? AND fp.sfrq <=? AND a.GZFL LIKE 'KSS%' GROUP BY b.CFYS, a.SFXMC, yp.GG, yp.DXSL, yp.DDD ]]></sql> //医生,药品名称,规格,等效数量,数量,金额,DDD值,DDDS <fields> <f name="医生" type="12" /> <f name="药品名称" type="12" /> <f name="规格" type="12" /> <f name="等效数量" type="8" /> <f name="数量" type="4" /> <f name="金额" type="4" /> <f name="DDD值" type="8" /> <f name="DDDS" type="4" /> </fields> <parameter> <p>12</p> <p>12</p> <p>93</p> <p>93</p> </parameter> </dao> </datasource> </window>
Loading…
Cancel
Save