You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
klhis/WEB-INF/conf/sysds_mms_wzff.xml

1757 lines
97 KiB

3 months ago
<?xml version="1.0" encoding="UTF-8"?>
<datasource>
<!-- 1 表示 sql语句dao 2表示存储过程dao 默认为sql语句dao-->
<!--出入库类型字典 000022-->
<dao id="mmsMzfyDfyLbByPkeyDao" log="true" type="1" memo="门诊发物资待发物资列表实际进行发物资dao">
<sql>
select b.xm,c.JZKH,a.PKEY,a.CJRQ,c.JJKS,a.cfh,a.FYCK,a.FYYF,a.FYZT,a.SFDY,a.SFTY,a.PYZT,a.SHZT,b.XB,c.JZNL,c.ISJZ,a.JGID,a.HZPKEY,a.JZPKEY,a.MZFPPKEY,a.ZDZBPKEY,a.PYR,a.PYRQ,a.SHR,a.SHRQ,a.FYR,a.FYRQ,a.LOCKFLAG from HIS_MMS_MZDFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey where a.JGID=? and a.PKEY=?
</sql>
<tables>
<table name="HIS_MMS_MZDFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="XM" type="12" />
<f name="JZKH" type="12" />
<f name="PKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="JJKS" type="12" />
<f name="CFH" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYCK" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SFDY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SFTY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SHZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="XB" type="12" />
<f name="JZNL" type="12" />
<f name="ISJZ" type="12" />
<f name="JGID" type="12" table="HIS_MMS_MZDFYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYR" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="SHR" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SHRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="FYR" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZDFYZB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfyDfyMxLbDao" log="true" type="1" memo="待发物资明细列表">
<sql>
select a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL,a.DFYPKEY,a.FYMXPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.YZDL,b.YZMC,b.YZDW,b.YZJL,b.YZJLDW,b.YZPC,b.YZLC,b.YZJE,b.YZBZ,b.YZXZYS,b.YZXZKS,b.YZDJSL,b.PKEY YZPKEY,b.YZYF,b.YPYZJBDW JBDW,b.YZJZZHXS,b.YPYZJBJG,a.TYSL,a.SFSL,a.FYZT,a.LOCKFLAG,c.WZGG,c.WZCS,d.ybbm,d.ybmc,a.ZSMCJ from HIS_MMS_PYB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_MMS_WZZD c on a.YZX=c.WZBM and a.JGID=c.JGID left join his_sfx d on c.wzbm=d.glbm and d.JGID=c.JGID where a.JGID=? and a.DFYPKEY=? order by a.pkey
</sql>
<tables>
<table name="HIS_YZ_MXB" insert="true" update="true" delete="true">
<primary>YZPKEY</primary>
<primary>YZDJSL</primary>
<primary>HZPKEY</primary>
<primary>JZPKEY</primary>
<primary>JGID</primary>
</table>
<table name="HIS_MMS_PYB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_PYB" />
<f name="YZX" type="12" table="HIS_MMS_PYB" />
<f name="YZMX" type="12" table="HIS_MMS_PYB" />
<f name="YZDJ" type="12" table="HIS_MMS_PYB" />
<f name="YZSL" type="12" table="HIS_MMS_PYB" />
<f name="DFYPKEY" type="12" table="HIS_MMS_PYB" />
<f name="FYMXPKEY" type="12" table="HIS_MMS_PYB" />
<f name="HZBQ" type="12" table="HIS_MMS_PYB" />
<f name="HZKS" type="12" table="HIS_MMS_PYB" />
<f name="FYKS" type="12" table="HIS_MMS_PYB" />
<f name="HZPKEY" type="12" table="HIS_YZ_MXB,HIS_MMS_PYB" />
<f name="YPFL" type="12" table="HIS_MMS_PYB" />
<f name="JZPKEY" type="12" table="HIS_YZ_MXB,HIS_MMS_PYB" />
<f name="TYPE" type="12" table="HIS_MMS_PYB" />
<f name="CJR" type="12" table="HIS_MMS_PYB" />
<f name="CJRQ" type="93" table="HIS_MMS_PYB" />
<f name="XGR" type="12" table="HIS_MMS_PYB" />
<f name="XGRQ" type="93" table="HIS_MMS_PYB" />
<f name="JGID" type="12" table="HIS_YZ_MXB,HIS_MMS_PYB" />
<f name="YZDL" type="12" table="HIS_MMS_PYB" />
<f name="YZMC" type="12" />
<f name="YZDW" type="12" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZLC" type="12" />
<f name="YZJE" type="12" />
<f name="YZBZ" type="12" />
<f name="YZXZYS" type="12" />
<f name="YZXZKS" type="12" />
<f name="YZDJSL" type="12" table="HIS_YZ_MXB" />
<f name="YZPKEY" schemaname="PKEY" type="12" table="HIS_YZ_MXB" />
<f name="YZYF" type="12" table="HIS_YZ_MXB" />
<f name="JBDW" type="12" />
<f name="YZJZZHXS" type="12" table="HIS_YZ_MXB" />
<f name="YPYZJBJG" type="12" table="HIS_YZ_MXB" />
<f name="TYSL" type="12" table="HIS_MMS_PYB" />
<f name="SFSL" type="12" table="HIS_MMS_PYB" />
<f name="FYZT" type="12" table="HIS_MMS_PYB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_PYB" />
<f name="WZGG" type="12" />
<f name="WZCS" type="12" />
<f name="YBBM" type="12" />
<f name="YBMC" type="12" />
<f name="ZSMCJ" type="12" table="HIS_MMS_PYB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfymxbDao" log="true" type="1" memo="专门用于门诊发物资的门诊发物资明细表dao">
<sql>select PKEY,YZX,YZMX,YZDJ,YZSL,FYBPKEY,HZBQ,HZKS,FYKS,HZPKEY,YPFL,JZPKEY,TYPE,YZDL,TYSL,CJR,CJRQ,XGR,XGRQ,JGID,KSKCPKEY,KSKCPCPKEY,LOCKFLAG from HIS_MMS_MZFYMXB where 1=2</sql>
<tables>
<table name="HIS_MMS_MZFYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZSL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYBPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZBQ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="TYPE" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZDL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="TYSL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="XGR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="JGID" type="12" table="HIS_MMS_MZFYMXB" />
<f name="KSKCPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="KSKCPCPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZFYMXB" />
</fields>
</dao>
<dao id="mmsMzfyZbDao" log="true" type="1" memo="门诊发物资主表">
<sql>select PKEY,HZPKEY,JZPKEY,MZFPPKEY,ZDZBPKEY,FYCK,FYYF,FYZT,SFDY,SFTY,CFH,PYZT,SHZT,PYR,PYRQ,SHR,SHRQ,DFYBPKEY,CJR,CJRQ,XGR,XGRQ,JGID,FYR,FYRQ,LOCKFLAG from HIS_MMS_MZFYZB where 1=2</sql>
<tables>
<table name="HIS_MMS_MZFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYCK" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFDY" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFTY" type="12" table="HIS_MMS_MZFYZB" />
<f name="CFH" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYR" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="SHR" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="DFYBPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="CJR" type="12" table="HIS_MMS_MZFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="XGR" type="12" table="HIS_MMS_MZFYZB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="JGID" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYR" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZFYZB" />
</fields>
</dao>
<dao id="mmsMzfyDfyLbDao" log="true" type="1" memo="门诊待发物资表dao,用于自动扣减待发物资的自动任务获取全部待发表所用">
<sql><![CDATA[select distinct pkey,JZPKEY from (select a.pkey,a.JZPKEY from HIS_MMS_MZDFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey left join HIS_MZJS_MZFPZB d on a.MZFPPKEY=d.pkey and a.JGID=d.JGID where a.FYZT=0 and a.JGID=? and d.SFZT=1 and a.CJRQ >=? and a.CJRQ <=? order by a.CJRQ desc)]]></sql>
<fields>
<f name="PKEY" type="12" />
<f name="JZPKEY" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsMztyDQZDZBDao" log="true" type="1" memo="门诊退物资判断当前账单主表有效性dao">
<sql>select a.PKEY,a.HZPKEY,a.JZPKEY,a.MZFPPKEY,a.ZDZBPKEY,a.FYCK,a.FYYF,a.FYZT,a.SFDY,a.SFTY,a.CFH,a.PYZT,a.SHZT,a.PYR,a.PYRQ,a.SHR,a.SHRQ,a.DFYBPKEY,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,b.JZZDPKEY,a.LOCKFLAG from HIS_MMS_MZFYZB a left join HIS_SFZD_ZB b on b.JZZDPKEY=a.ZDZBPKEY and a.JGID=b.JGID where b.JSZT=1 and b.ISHC=0 and a.JGID=? and b.JZZDPKEY=? order by a.CJRQ desc </sql>
<tables>
<table name="HIS_MMS_MZFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYCK" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFDY" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFTY" type="12" table="HIS_MMS_MZFYZB" />
<f name="CFH" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYR" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="SHR" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="DFYBPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="CJR" type="12" table="HIS_MMS_MZFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="XGR" type="12" table="HIS_MMS_MZFYZB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="JGID" type="12" table="HIS_MMS_MZFYZB" />
<f name="JZZDPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZFYZB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMztftyFymxbDao" log="true" type="1" memo="门诊退费退物资患者已发物资明细dao">
<sql>
select a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL,a.FYBPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.YZDL,a.TYSL,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.KSKCPKEY,a.KSKCPCPKEY,b.CFH,b.YZMC,b.YZDW,b.YZJL,b.YZJLDW,b.YZPC,b.YZLC,b.YZJE,b.YZBZ,b.YZXZYS,b.YZXZKS,b.YZDJSL,b.PKEY YZPKEY,b.YZYF,b.YPYZJBDW JBDW,b.YZJZZHXS,b.YPYZJBJG,a.LOCKFLAG from HIS_MMS_MZFYMXB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_MMS_MZFYZB c on a.FYBPKEY=c.PKEY and a.JGID=c.JGID left join HIS_SFZD_ZB d on d.JZZDPKEY=c.ZDZBPKEY and d.JGID=c.JGID where a.JGID=? and c.pkey=? and d.JSZT=1 and d.ISHC=0 order by b.cfh,a.pkey
</sql>
<tables>
<table name="HIS_MMS_MZFYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZSL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYBPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZBQ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="TYPE" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZDL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="TYSL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="XGR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="JGID" type="12" table="HIS_MMS_MZFYMXB" />
<f name="KSKCPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="KSKCPCPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CFH" type="12" />
<f name="YZMC" type="12" />
<f name="YZDW" type="12" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZLC" type="12" />
<f name="YZJE" type="12" />
<f name="YZBZ" type="12" />
<f name="YZXZYS" type="12" />
<f name="YZXZKS" type="12" />
<f name="YZDJSL" type="12" />
<f name="YZPKEY" type="12" />
<f name="YZYF" type="12" />
<f name="JBDW" type="12" />
<f name="YZJZZHXS" type="12" />
<f name="YPYZJBJG" type="12" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZFYMXB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMztynewTyZBDao" log="true" type="1" memo="新增门诊退物资的门诊退物资主表dao">
<sql>select PKEY,HZPKEY,JZPKEY,MZFPPKEY,ZDZBPKEY,JZZDPKEY,JZMZFPPKEY,MZFYBPKEY,TYYF,TYRY,FYYF,TYYY,CJR,CJRQ,XGR,XGRQ,JGID,FYRQ,ISCX,CFH,LOCKFLAG from HIS_MMS_MZTYZB where 1=2</sql>
<tables>
<table name="HIS_MMS_MZTYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="JZZDPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="JZMZFPPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="MZFYBPKEY" type="12" table="HIS_MMS_MZTYZB" />
<f name="TYYF" type="12" table="HIS_MMS_MZTYZB" />
<f name="TYRY" type="12" table="HIS_MMS_MZTYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZTYZB" />
<f name="TYYY" type="12" table="HIS_MMS_MZTYZB" />
<f name="CJR" type="12" table="HIS_MMS_MZTYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZTYZB" />
<f name="XGR" type="12" table="HIS_MMS_MZTYZB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZTYZB" />
<f name="JGID" type="12" table="HIS_MMS_MZTYZB" />
<f name="FYRQ" type="93" table="HIS_MMS_MZTYZB" />
<f name="ISCX" type="12" table="HIS_MMS_MZTYZB" />
<f name="CFH" type="12" table="HIS_MMS_MZTYZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_MZTYZB" />
</fields>
</dao>
<dao id="mmsMztnewTyMxbDao" log="true" type="1" memo="门诊退物资的门诊退物资明细表,这里住院退物资也采用此dao">
<sql>select PKEY,YZX,YZMX,YZDJ,TYSL,HZBQ,HZKS,TYKS,HZPKEY,YPFL,JZPKEY,TYBPKEY,TYPE,KSKCPKEY,KSKCPCPKEY,CJR,CJRQ,XGR,XGRQ,JGID,MZFYMXBPKEY,PYBPKEY,TYDH,TYYY,BED,CFH,ZYNO,LOCKFLAG,ZSMCJ from HIS_MMS_MZTYMXB where 1=2</sql>
<tables>
<table name="HIS_MMS_MZTYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="YZX" type="12" table="HIS_MMS_MZTYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_MZTYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYSL" type="12" table="HIS_MMS_MZTYMXB" />
<f name="HZBQ" type="12" table="HIS_MMS_MZTYMXB" />
<f name="HZKS" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYKS" type="12" table="HIS_MMS_MZTYMXB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_MZTYMXB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYBPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYPE" type="12" table="HIS_MMS_MZTYMXB" />
<f name="KSKCPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="KSKCPCPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="CJR" type="12" table="HIS_MMS_MZTYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZTYMXB" />
<f name="XGR" type="12" table="HIS_MMS_MZTYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZTYMXB" />
<f name="JGID" type="12" table="HIS_MMS_MZTYMXB" />
<f name="MZFYMXBPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="PYBPKEY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYDH" type="12" table="HIS_MMS_MZTYMXB" />
<f name="TYYY" type="12" table="HIS_MMS_MZTYMXB" />
<f name="BED" type="12" table="HIS_MMS_MZTYMXB" />
<f name="CFH" type="12" table="HIS_MMS_MZTYMXB" />
<f name="ZYNO" type="12" table="HIS_MMS_MZTYMXB" />
<f name="LOCKFLAG" type="-5" table="HIS_MMS_MZTYMXB" />
<f name="ZSMCJ" type="12" table="HIS_MMS_MZTYMXB" />
</fields>
</dao>
<dao id="mmsZyjsyAutofyPybMxDao" log="true" type="1" memo="住院物资自动发物资的发物资明细dao">
<sql><![CDATA[
select b.cfh,d.JJKS,d.ZYNO,a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL,a.DFYPKEY,a.FYMXPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.YZDL,a.TYSL,a.SFSL,a.SFLYSH,a.SFYSSH,a.LYSHR,a.LYSHRQ,a.YSSHR,a.YSSHRQ,a.FYZT,d.ward,d.bed,d.jjys,f.xm,e.zxtime,a.yzsl*b.YZJZZHXS jzyzsl,b.YPYZJBDW,b.YZJZZHXS,b.YZMC,b.YZJL,b.YZJLDW,b.YZPC,b.yzcl,e.pkey execpkey,e.SFFLAG,b.YPYZJBJG,a.yzsl*b.yzjzzhxs*b.YPYZJBJG je,b.YZJX,a.SFSL*b.YZJZZHXS jzsfsl,e.zxsl,e.zxje,b.yzxpkey,b.YZXZSJ,e.ISACTION,b.YZLX,b.YZZCYFS,b.YZYF,a.FYCX,e.ZXFLAG,a.LOCKFLAG,e.ZXRKS,b.YZZXKS from HIS_MMS_PYB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_JZ_BASEINFO d on a.JZPKEY=d.pkey and a.JGID=d.JGID left join HIS_YZ_EXEC e on a.DFYPKEY=e.pkey and a.JGID=e.JGID left join HIS_HZINFO f on a.hzpkey=f.pkey and a.JGID=f.JGID where a.TYPE='Z' AND a.FYCX=0 and a.FYZT=0 AND d.JZLX='Z' AND d.JZZT='Z' AND a.PYLX='3' and a.JGID=? and b.YZZXKS=? and e.zxtime >=? and e.zxtime <= ?
]]></sql>
<tables>
<table name="HIS_MMS_PYB" insert="false" update="true" delete="false">
<primary>PKEY</primary>
<primary>YZMX</primary>
<primary>FYMXPKEY</primary>
<primary>FYZT</primary>
<primary>FYCX</primary>
</table>
<table name="HIS_YZ_EXEC" insert="false" update="true" delete="false">
<primary>EXECPKEY</primary>
<primary>YZMX</primary>
<primary>JZPKEY</primary>
<primary>SFFLAG</primary>
<primary>ISACTION</primary>
<primary>ZXFLAG</primary>
</table>
</tables>
<fields>
<f name="CFH" type="12" table="HIS_YZ_EXEC" />
<f name="JJKS" type="12" />
<f name="ZYNO" type="12" table="HIS_YZ_EXEC" />
<f name="PKEY" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="YZX" type="12" table="HIS_MMS_PYB" />
<f name="YZMX" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="YZDJ" type="12" table="HIS_MMS_PYB" />
<f name="YZSL" type="12" table="HIS_MMS_PYB" />
<f name="DFYPKEY" type="12" table="HIS_MMS_PYB" />
<f name="FYMXPKEY" type="12" table="HIS_MMS_PYB" />
<f name="HZBQ" type="12" table="HIS_MMS_PYB" />
<f name="HZKS" type="12" table="HIS_MMS_PYB" />
<f name="FYKS" type="12" table="HIS_MMS_PYB" />
<f name="HZPKEY" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="YPFL" type="12" table="HIS_MMS_PYB" />
<f name="JZPKEY" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="TYPE" type="12" table="HIS_MMS_PYB" />
<f name="CJR" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="CJRQ" type="93" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="XGR" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="XGRQ" type="93" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="JGID" type="12" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="YZDL" type="12" table="HIS_MMS_PYB" />
<f name="TYSL" type="12" table="HIS_MMS_PYB" />
<f name="SFSL" type="12" table="HIS_MMS_PYB" />
<f name="SFLYSH" type="12" table="HIS_MMS_PYB" />
<f name="SFYSSH" type="12" table="HIS_MMS_PYB" />
<f name="LYSHR" type="12" table="HIS_MMS_PYB" />
<f name="LYSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="YSSHR" type="12" table="HIS_MMS_PYB" />
<f name="YSSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="FYZT" type="12" table="HIS_MMS_PYB" />
<f name="WARD" type="12" />
<f name="BED" type="12" />
<f name="JJYS" type="12" />
<f name="XM" type="12" />
<f name="ZXTIME" type="93" table="HIS_YZ_EXEC" />
<f name="JZYZSL" type="4" />
<f name="YPYZJBDW" type="12" />
<f name="YZJZZHXS" type="12" />
<f name="YZMC" type="12" table="HIS_YZ_EXEC" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZCL" type="12" />
<f name="EXECPKEY" type="12" />
<f name="SFFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="YPYZJBJG" type="12" />
<f name="JE" type="4" />
<f name="YZJX" type="12" />
<f name="JZSFSL" type="4" />
<f name="ZXSL" type="8" table="HIS_YZ_EXEC" />
<f name="ZXJE" type="8" table="HIS_YZ_EXEC" />
<f name="YZXPKEY" type="12" table="HIS_YZ_EXEC" />
<f name="YZXZSJ" type="93" />
<f name="ISACTION" type="12" table="HIS_YZ_EXEC" />
<f name="YZLX" type="12" />
<f name="YZZCYFS" type="12" />
<f name="YZYF" type="12" />
<f name="FYCX" type="12" table="HIS_MMS_PYB" />
<f name="ZXFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="LOCKFLAG" type="-5" table="HIS_YZ_EXEC,HIS_MMS_PYB" />
<f name="ZXRKS" type="12" table="HIS_YZ_EXEC" />
<f name="YZZXKS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsZyjsyAutofyPybMxKsflDao" log="true" type="1" memo="住院物资自动发物资的发物资明细所属科室dao">
<sql><![CDATA[
select b.YZZXKS from HIS_MMS_PYB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_JZ_BASEINFO d on a.JZPKEY=d.pkey and a.JGID=d.JGID left join HIS_YZ_EXEC e on a.DFYPKEY=e.pkey and a.JGID=e.JGID where a.TYPE='Z' AND a.FYCX=0 and a.FYZT=0 AND d.JZLX='Z' AND d.JZZT='Z' AND a.PYLX='3' and a.JGID=? and e.zxtime >=? and e.zxtime <= ? group by b.YZZXKS
]]></sql>
<fields>
<f name="YZZXKS" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsZyfymxbdao" log="true" type="1" memo="住院物资房发物资明细dao">
<sql>select PKEY,FYBPKEY,JZPKEY,HZPKEY,ZYNO,CFH,PYBPKEY,YZXPKEY,YZMX,YZDJ,YZSL,BED,YPFL,YZDL,TYSL,KSKCPKEY,KSKCPCPKEY,CJR,CJRQ,XGR,XGRQ,JGID,EXEPKEY,LOCKFLAG from HIS_MMS_ZYFYMXB where 1=2</sql>
<tables>
<table name="HIS_MMS_ZYFYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>FYBPKEY</primary>
<primary>JZPKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="FYBPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="JZPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="HZPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="ZYNO" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CFH" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="PYBPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZXPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZSL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="BED" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZDL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="TYSL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="KSKCPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="KSKCPCPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CJR" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYFYMXB" />
<f name="XGR" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_ZYFYMXB" />
<f name="JGID" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="EXEPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_ZYFYMXB" />
</fields>
</dao>
<dao id="mmsZyfyzbdao" log="true" type="1" memo="住院发物资主表dao">
<sql>select PKEY,FYR,FYKS,FYTIME,HZBQ,PRINTFLAG,PRINTTIME,FYLB,FYKSSJ,FYJSSJ,FYDH,FYITEMS,CJR,CJRQ,XGR,XGRQ,JGID,HZKS,LOCKFLAG from HIS_MMS_ZYFYZB where 1=2</sql>
<tables>
<table name="HIS_MMS_ZYFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_ZYFYZB" />
<f name="FYR" type="12" table="HIS_MMS_ZYFYZB" />
<f name="FYKS" type="12" table="HIS_MMS_ZYFYZB" />
<f name="FYTIME" type="93" table="HIS_MMS_ZYFYZB" />
<f name="HZBQ" type="12" table="HIS_MMS_ZYFYZB" />
<f name="PRINTFLAG" type="12" table="HIS_MMS_ZYFYZB" />
<f name="PRINTTIME" type="93" table="HIS_MMS_ZYFYZB" />
<f name="FYLB" type="12" table="HIS_MMS_ZYFYZB" />
<f name="FYKSSJ" type="93" table="HIS_MMS_ZYFYZB" />
<f name="FYJSSJ" type="93" table="HIS_MMS_ZYFYZB" />
<f name="FYDH" type="12" table="HIS_MMS_ZYFYZB" />
<f name="FYITEMS" type="-5" table="HIS_MMS_ZYFYZB" />
<f name="CJR" type="12" table="HIS_MMS_ZYFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYFYZB" />
<f name="XGR" type="12" table="HIS_MMS_ZYFYZB" />
<f name="XGRQ" type="93" table="HIS_MMS_ZYFYZB" />
<f name="JGID" type="12" table="HIS_MMS_ZYFYZB" />
<f name="HZKS" type="12" table="HIS_MMS_ZYFYZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_ZYFYZB" />
</fields>
</dao>
<dao id="newMMSZytySqdDao" log="true" type="1" memo="建立新的住院退物资申请单dao">
<sql>select PKEY,TYDH,HZPKEY,JZPKEY,ZYNO,BED,WARD,SQKS,JSKS,JJKS,EXEPKEY,PYBPKEY,YZMX,YZXPKEY,CFH,SQSL,YZDJ,YZJE,STATE,KDYS,SQR,CJR,CJRQ,XGR,XGRQ,JGID,TYR,TYRQ,LOCKFLAG from HIS_MMS_ZYTYSQB where 1=2</sql>
<tables>
<table name="HIS_MMS_ZYTYSQB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="TYDH" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="HZPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JZPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="ZYNO" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="BED" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="WARD" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JSKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JJKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="EXEPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="PYBPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZMX" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZXPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CFH" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQSL" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZDJ" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZJE" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="STATE" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="KDYS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CJR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="XGR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="XGRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="JGID" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="TYR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="TYRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_ZYTYSQB" />
</fields>
</dao>
<dao id="newMMSZytySqdZBDao" log="true" type="1" memo="住院退物资申请表主表dao">
<sql>select TYDH,CJR,CJRQ,JGID,LOCKFLAG from HIS_MMS_ZYTYSQBZB where 1=2</sql>
<tables>
<table name="HIS_MMS_ZYTYSQBZB" insert="true" update="true" delete="true">
<primary>TYDH</primary>
</table>
</tables>
<fields>
<f name="TYDH" type="12" table="HIS_MMS_ZYTYSQBZB" />
<f name="CJR" type="12" table="HIS_MMS_ZYTYSQBZB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYTYSQBZB" />
<f name="JGID" type="12" table="HIS_MMS_ZYTYSQBZB" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_ZYTYSQBZB" />
</fields>
</dao>
<dao id="mmsTyBySqdExecOrderMxDao" log="true" type="1" memo="用于通过退物资申请单退物资显示所有允许退物资的执行医嘱明细dao">
<sql>
select * from (select distinct a.yzmx||'|'||a.QUERYCODE flagcode,a.PKEY,a.JZPKEY,a.HZPKEY,a.YZMX,a.YZXPKEY,a.ZXFLAG,a.ZXR,a.ZXTIME,a.ZXRKS,a.ZXRWARD,a.PRINTFLAG,a.PRINTMAN,a.PRINTTIME,a.BBCJFLAG,a.BBCJMAN,a.BBCJTIME,a.BBTM,a.QUERYCODE,a.SFFLAG,a.ZXSL,a.ZXDW,a.ZXJE,a.YZBEGINSJ,a.YZZXBEGINSJ,a.YZTZSJ,a.YZMS,a.JZBZ,a.ZDZBPKEY,a.CXR,a.CXSJ,a.TZR,a.TZSJ,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.CFH,a.YZMC,a.ISACTION,e.PKEY pybpkey,e.SFLYSH,e.SFYSSH,e.LYSHR,e.LYSHRQ,e.YSSHR,e.YSSHRQ,e.FYZT
,(select sum(YZSL) YZSL from HIS_MMS_ZYFYMXB where PYBPKEY=e.pkey and yzmx=e.yzmx and JGID=e.JGID) FYMXBYZSL
,(select sum(TYSL) TYSL from HIS_MMS_ZYFYMXB where PYBPKEY=e.pkey and yzmx=e.yzmx and JGID=e.JGID) FYMXBTYSL
,e.YPFL,e.TYSL,fyzb.FYKS,f.YZXZYS,f.YZLB,h.zyno,h.zybah,h.bed,i.xm,h.ward,a.TYDNUM,h.jjks,(select sum(sqsl) sqsl from HIS_MMS_ZYTYSQB where exepkey=a.pkey and JGID=a.JGID and STATE != 2) sqsl,f.YZJZZHXS,f.YPYZJBDW,g.TYDH,e.LOCKFLAG
from HIS_YZ_EXEC a left join HIS_MMS_PYB e on a.pkey=e.DFYPKEY and a.JGID=e.JGID left join HIS_YZ_MXB f on a.YZMX=f.pkey and a.JGID=f.JGID left join HIS_JZ_BASEINFO h on a.jzpkey=h.pkey and a.JGID=h.JGID left join HIS_HZINFO i on a.hzpkey=i.pkey and a.JGID=i.JGID left join HIS_MMS_ZYTYSQB g on g.exepkey=a.pkey and g.JGID=a.JGID left join HIS_MMS_ZYFYMXB fymx on fymx.YZMX=a.yzmx and fymx.JGID=a.JGID left join HIS_MMS_ZYFYZB fyzb on fymx.FYBPKEY=fyzb.pkey and fyzb.JGID=fymx.JGID
where a.JGID=? #query# and (a.ZXFLAG=2 or a.ZXFLAG=3) and e.FYZT=1 and (h.JZLX='Z' or (h.JZLX='J' OR h.SFLG='1')) and h.ISZZCWJS != '1' and g.state=0 order by a.ZXTIME desc ) where (nvl(FYMXBYZSL,0)-nvl(FYMXBTYSL,0))>0 and nvl(sqsl,0) > 0
</sql>
<tables>
<table name="HIS_MMS_PYB" insert="false" update="true" delete="false">
<primary>TYSL</primary>
<primary>PYBPKEY</primary>
<primary>YZMX</primary>
<primary>JGID</primary>
</table>
<table name="HIS_YZ_EXEC" insert="false" update="true" delete="true">
<primary>PKEY</primary>
<primary>SFFLAG</primary>
<primary>ISACTION</primary>
<primary>ZXFLAG</primary>
<primary>JGID</primary>
<primary>TYDNUM</primary>
</table>
</tables>
<fields>
<f name="FLAGCODE" type="12" />
<f name="PKEY" type="12" table="HIS_YZ_EXEC" />
<f name="JZPKEY" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="HZPKEY" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="YZMX" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="YZXPKEY" type="12" table="HIS_YZ_EXEC" />
<f name="ZXFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="ZXR" type="12" table="HIS_YZ_EXEC" />
<f name="ZXTIME" type="93" table="HIS_YZ_EXEC" />
<f name="ZXRKS" type="12" table="HIS_YZ_EXEC" />
<f name="ZXRWARD" type="12" table="HIS_YZ_EXEC" />
<f name="PRINTFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="PRINTMAN" type="12" table="HIS_YZ_EXEC" />
<f name="PRINTTIME" type="93" table="HIS_YZ_EXEC" />
<f name="BBCJFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="BBCJMAN" type="12" table="HIS_YZ_EXEC" />
<f name="BBCJTIME" type="93" table="HIS_YZ_EXEC" />
<f name="BBTM" type="12" table="HIS_YZ_EXEC" />
<f name="QUERYCODE" type="12" table="HIS_YZ_EXEC" />
<f name="SFFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="ZXSL" type="8" table="HIS_YZ_EXEC" />
<f name="ZXDW" type="12" table="HIS_YZ_EXEC" />
<f name="ZXJE" type="8" table="HIS_YZ_EXEC" />
<f name="YZBEGINSJ" type="93" table="HIS_YZ_EXEC" />
<f name="YZZXBEGINSJ" type="93" table="HIS_YZ_EXEC" />
<f name="YZTZSJ" type="93" table="HIS_YZ_EXEC" />
<f name="YZMS" type="12" table="HIS_YZ_EXEC" />
<f name="JZBZ" type="12" table="HIS_YZ_EXEC" />
<f name="ZDZBPKEY" type="12" table="HIS_YZ_EXEC" />
<f name="CXR" type="12" table="HIS_YZ_EXEC" />
<f name="CXSJ" type="93" table="HIS_YZ_EXEC" />
<f name="TZR" type="12" table="HIS_YZ_EXEC" />
<f name="TZSJ" type="93" table="HIS_YZ_EXEC" />
<f name="CJR" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="CJRQ" type="93" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="XGR" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="XGRQ" type="93" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="JGID" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="CFH" type="12" table="HIS_YZ_EXEC" />
<f name="YZMC" type="12" table="HIS_YZ_EXEC" />
<f name="ISACTION" type="12" table="HIS_YZ_EXEC" />
<f name="PYBPKEY" schemaname="pkey" type="12" table="HIS_MMS_PYB" />
<f name="SFLYSH" type="12" table="HIS_MMS_PYB" />
<f name="SFYSSH" type="12" table="HIS_MMS_PYB" />
<f name="LYSHR" type="12" table="HIS_MMS_PYB" />
<f name="LYSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="YSSHR" type="12" table="HIS_MMS_PYB" />
<f name="YSSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="FYZT" type="12" table="HIS_MMS_PYB" />
<f name="FYMXBYZSL" type="8" />
<f name="FYMXBTYSL" type="8" />
<f name="YPFL" type="12" table="HIS_MMS_PYB" />
<f name="TYSL" type="12" table="HIS_MMS_PYB" />
<f name="FYKS" type="12" table="HIS_MMS_PYB" />
<f name="YZXZYS" type="12" />
<f name="YZLB" type="12" />
<f name="ZYNO" type="12" table="HIS_YZ_EXEC" />
<f name="ZYBAH" type="12" />
<f name="BED" type="12" />
<f name="XM" type="12" />
<f name="WARD" type="12" />
<f name="TYDNUM" type="8" table="HIS_YZ_EXEC" />
<f name="JJKS" type="12" />
<f name="SQSL" type="8" />
<f name="YZJZZHXS" type="12" />
<f name="YPYZJBDW" type="12" />
<f name="TYDH" type="12" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_PYB" />
</fields>
<parameter>
<p>12</p>
</parameter>
</dao>
<dao id="mmsZyTyAllTySqdMxDao" log="true" type="1" memo="通过退药申请单进行住院退药,获取所有执行医嘱对应的有效申请单dao">
<sql>
select g.PKEY,g.TYDH,g.HZPKEY,g.JZPKEY,g.ZYNO,g.BED,g.WARD,g.SQKS,g.JSKS,g.JJKS,g.EXEPKEY,g.PYBPKEY,g.YZMX,g.YZXPKEY,g.CFH,g.SQSL,g.YZDJ,g.YZJE,g.STATE,g.KDYS,g.SQR,g.CJR,g.CJRQ,g.XGR,g.XGRQ,g.JGID,i.xm,g.TYR,g.TYRQ,g.LOCKFLAG
from HIS_MMS_ZYTYSQB g
left join HIS_YZ_EXEC a on a.pkey=g.exepkey and a.JGID=g.JGID
left join HIS_MMS_PYB e on a.pkey=e.DFYPKEY and a.JGID=e.JGID
left join HIS_JZ_BASEINFO h on a.jzpkey=h.pkey and a.JGID=h.JGID
left join HIS_HZINFO i on a.hzpkey=i.pkey and a.JGID=i.JGID
where a.JGID=? #query# and (a.ZXFLAG=2 or a.ZXFLAG=3) and e.FYZT=1 and h.JZLX='Z' and h.JZZT='Z' and h.ISZZCWJS != '1' and g.STATE=0 order by a.ZXTIME desc
</sql>
<tables>
<table name="HIS_MMS_ZYTYSQB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>STATE</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="TYDH" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="HZPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JZPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="ZYNO" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="BED" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="WARD" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JSKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="JJKS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="EXEPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="PYBPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZMX" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZXPKEY" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CFH" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQSL" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZDJ" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="YZJE" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="STATE" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="KDYS" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="SQR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CJR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="XGR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="XGRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="JGID" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="XM" type="12" />
<f name="TYR" type="12" table="HIS_MMS_ZYTYSQB" />
<f name="TYRQ" type="93" table="HIS_MMS_ZYTYSQB" />
<f name="LOCKFLAG" type="8" table="HIS_MMS_ZYTYSQB" />
</fields>
<parameter>
<p>12</p>
</parameter>
</dao>
<dao id="mmsZyTyAllTyOrdFyMxDao" log="true" type="1">
<sql>
select fymxb.PKEY,fymxb.FYBPKEY,fymxb.JZPKEY,fymxb.HZPKEY,fymxb.ZYNO,fymxb.CFH,fymxb.PYBPKEY,fymxb.YZXPKEY,fymxb.YZMX,fymxb.YZDJ,fymxb.YZSL,fymxb.BED,fymxb.YPFL,fymxb.YZDL,fymxb.TYSL,fymxb.KSKCPKEY,fymxb.KSKCPCPKEY,fymxb.CJR,fymxb.CJRQ,fymxb.XGR,fymxb.XGRQ,fymxb.JGID,fymxb.EXEPKEY,b.YZMC,b.YZDW,b.YZJL,b.YZJLDW,b.YZPC,b.YZLC,b.YZJE,b.YZBZ,b.YZXZYS,b.YZXZKS,b.YZDJSL,b.YZYF,b.YPYZJBDW JBDW,b.YZJZZHXS,b.YPYZJBJG,i.XM,fymxb.LOCKFLAG from HIS_MMS_ZYFYMXB fymxb
left join HIS_YZ_EXEC a on a.pkey=fymxb.exepkey and a.JGID=fymxb.JGID
left join HIS_MMS_PYB e on a.pkey=e.DFYPKEY and a.JGID=e.JGID
left join HIS_JZ_BASEINFO h on a.jzpkey=h.pkey and a.JGID=h.JGID
left join HIS_HZINFO i on a.hzpkey=i.pkey and a.JGID=i.JGID
left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID
left join HIS_MMS_ZYTYSQB g on g.exepkey=a.pkey and g.JGID=a.JGID
where a.JGID=? #query# and (a.ZXFLAG=2 or a.ZXFLAG=3) and e.FYZT=1 and h.JZLX='Z' and h.JZZT='Z' and g.STATE=0 and h.ISZZCWJS != '1' order by a.ZXTIME desc
</sql>
<tables>
<table name="HIS_MMS_ZYFYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
<primary>EXEPKEY</primary>
<primary>TYSL</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="FYBPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="JZPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="HZPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="ZYNO" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CFH" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="PYBPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZXPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZSL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="BED" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZDL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="TYSL" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="KSKCPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="KSKCPCPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CJR" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_ZYFYMXB" />
<f name="XGR" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_ZYFYMXB" />
<f name="JGID" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="EXEPKEY" type="12" table="HIS_MMS_ZYFYMXB" />
<f name="YZMC" type="12" />
<f name="YZDW" type="12" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZLC" type="12" />
<f name="YZJE" type="12" />
<f name="YZBZ" type="12" />
<f name="YZXZYS" type="12" />
<f name="YZXZKS" type="12" />
<f name="YZDJSL" type="12" />
<f name="YZYF" type="12" />
<f name="JBDW" type="12" />
<f name="YZJZZHXS" type="12" />
<f name="YPYZJBJG" type="12" />
<f name="XM" type="12" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_ZYFYMXB" />
</fields>
<parameter>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfyDfyRylbDao" log="true" type="1" memo="门诊发耗材的待发放人员列表">
<sql><![CDATA[
select distinct JZNO,XM,JZKH,JJKS,JZPKEY,HZPKEY from (select c.jzno,b.xm,c.JZKH,a.CJRQ,c.JJKS,a.JZPKEY,a.hzpkey from HIS_MMS_MZDFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey left join HIS_MZJS_MZFPZB d on a.MZFPPKEY=d.pkey and a.JGID=d.JGID where a.FYZT=? and a.JGID=? and a.FYYF=? and d.SFZT=1 and a.CJRQ >=? and a.CJRQ <=? order by c.ISJZ desc,a.CJRQ)
]]></sql>
<fields>
<f name="JZNO" type="12" />
<f name="XM" type="12" />
<f name="JZKH" type="12" />
<f name="JJKS" type="12" />
<f name="JZPKEY" type="12" />
<f name="HZPKEY" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsAutoMzfyDfyLbDao" log="true" type="1" memo="门诊待发物资表dao,用于自动扣减待发物资的自动任务获取全部待发表所用">
<sql><![CDATA[select distinct pkey,JZPKEY from (select a.pkey,a.JZPKEY from HIS_MMS_MZDFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey left join HIS_MZJS_MZFPZB d on a.MZFPPKEY=d.pkey and a.JGID=d.JGID where a.FYZT=0 and a.JGID=? and d.SFZT=1 and a.FYZT=0 and a.CJRQ >=? and a.CJRQ <=? order by a.CJRQ desc)]]></sql>
<fields>
<f name="PKEY" type="12" />
<f name="JZPKEY" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsMzfyDfyLbDao" log="true" type="1" memo="门诊发耗材待发耗材列表dao">
<sql>
select b.xm,c.JZKH,a.PKEY,a.CJRQ,c.JJKS,a.cfh,a.FYCK,a.FYYF,a.FYZT,a.SFDY,a.SFTY,a.PYZT,a.SHZT,b.XB,c.JZNL,c.ISJZ,a.JGID,a.HZPKEY,a.JZPKEY,a.MZFPPKEY,a.ZDZBPKEY,a.PYR,a.PYRQ,a.SHR,a.SHRQ,a.LOCKFLAG from HIS_MMS_MZDFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey left join HIS_MZJS_MZFPZB d on a.MZFPPKEY=d.pkey and a.JGID=d.JGID where a.JGID=? and a.JZPKEY=? and a.FYYF=? and d.SFZT=1 and a.FYZT=0 order by c.ISJZ desc,a.cfh
</sql>
<tables>
<table name="HIS_MMS_MZDFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="XM" type="12" />
<f name="JZKH" type="12" />
<f name="PKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="JJKS" type="12" />
<f name="CFH" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYCK" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZDFYZB" />
<f name="FYZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SFDY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SFTY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SHZT" type="12" table="HIS_MMS_MZDFYZB" />
<f name="XB" type="12" />
<f name="JZNL" type="12" />
<f name="ISJZ" type="12" />
<f name="JGID" type="12" table="HIS_MMS_MZDFYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYR" type="12" table="HIS_MMS_MZDFYZB" />
<f name="PYRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="SHR" type="12" table="HIS_MMS_MZDFYZB" />
<f name="SHRQ" type="93" table="HIS_MMS_MZDFYZB" />
<f name="LOCKFLAG" type="-5" table="HIS_MMS_MZDFYZB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfyyfyMxLbDao" log="true" type="1" memo="已发药明细列表">
<sql>
select a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL/b.YZJZZHXS YZSL,a.FYBPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.YZDL,b.YZMC,b.YZDW,b.YZJL,b.YZJLDW,b.YZPC,b.YZLC,b.YZJE,b.YZBZ,b.YZXZYS,b.YZXZKS,b.YZDJSL,c.WZGG,c.WZCS,b.PKEY YZPKEY,b.YZYF,c.JBDW,b.YZJZZHXS,b.YPYZJBJG,a.TYSL/b.YZJZZHXS TYSL,a.LOCKFLAG,d.ybbm,d.ybmc from HIS_MMS_MZFYMXB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_MMS_WZZD c on a.YZX=c.WZBM left join his_sfx d on c.wzbm=d.glbm and d.JGID=c.JGID where a.JGID=? and a.FYBPKEY=? order by a.pkey
</sql>
<tables>
<table name="HIS_YZ_MXB" insert="true" update="true" delete="true">
<primary>YZPKEY</primary>
<primary>YZDJSL</primary>
<primary>HZPKEY</primary>
<primary>JZPKEY</primary>
<primary>JGID</primary>
</table>
<table name="HIS_MMS_MZFYMXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>YZX</primary>
<primary>YZMX</primary>
<primary>JGID</primary>
<primary>HZPKEY</primary>
<primary>JZPKEY</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZMX" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZDJ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZSL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYBPKEY" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZBQ" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="FYKS" type="12" table="HIS_MMS_MZFYMXB" />
<f name="HZPKEY" type="12" table="HIS_YZ_MXB,HIS_MMS_MZFYMXB" />
<f name="YPFL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="JZPKEY" type="12" table="HIS_YZ_MXB,HIS_MMS_MZFYMXB" />
<f name="TYPE" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="XGR" type="12" table="HIS_MMS_MZFYMXB" />
<f name="XGRQ" type="93" table="HIS_MMS_MZFYMXB" />
<f name="JGID" type="12" table="HIS_YZ_MXB,HIS_MMS_MZFYMXB" />
<f name="YZDL" type="12" table="HIS_MMS_MZFYMXB" />
<f name="YZMC" type="12" />
<f name="YZDW" type="12" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZLC" type="12" />
<f name="YZJE" type="12" />
<f name="YZBZ" type="12" />
<f name="YZXZYS" type="12" />
<f name="YZXZKS" type="12" />
<f name="YZDJSL" type="12" table="HIS_YZ_MXB" />
<f name="WZGG" type="12" />
<f name="WZCS" type="12" />
<f name="YZPKEY" schemaname="PKEY" type="12" table="HIS_YZ_MXB" />
<f name="YZYF" type="12" table="HIS_YZ_MXB" />
<f name="JBDW" type="12" />
<f name="YZJZZHXS" type="12" table="HIS_YZ_MXB" />
<f name="YPYZJBJG" type="12" table="HIS_YZ_MXB" />
<f name="TYSL" type="12"/>
<f name="LOCKFLAG" type="-5" table="HIS_MMS_MZFYMXB" />
<f name="YBBM" type="12" />
<f name="YBMC" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfyYfyLbDao" log="true" type="1" memo="门诊发药已发药列表dao">
<sql>
select b.xm,c.JZKH,a.PKEY,a.CJRQ,c.JJKS,a.cfh,a.FYCK,a.FYYF,a.FYZT,a.SFDY,a.SFTY,a.PYZT,a.SHZT,b.XB,c.JZNL,c.ISJZ,a.JGID,a.HZPKEY,a.JZPKEY,a.MZFPPKEY,a.ZDZBPKEY,a.PYR,a.PYRQ,a.SHR,a.SHRQ,a.fyr,a.fyrq,a.LOCKFLAG from HIS_MMS_MZFYZB a left join HIS_HZINFO b on a.hzpkey=b.pkey left join HIS_JZ_BASEINFO c on a.jzpkey=c.pkey where a.JGID=? and a.JZPKEY=? and a.FYYF=? order by c.ISJZ desc,a.cfh
</sql>
<tables>
<table name="HIS_MMS_MZFYZB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="XM" type="12" />
<f name="JZKH" type="12" />
<f name="PKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="CJRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="JJKS" type="12" />
<f name="CFH" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYCK" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYYF" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFDY" type="12" table="HIS_MMS_MZFYZB" />
<f name="SFTY" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHZT" type="12" table="HIS_MMS_MZFYZB" />
<f name="XB" type="12" />
<f name="JZNL" type="12" />
<f name="ISJZ" type="12" />
<f name="JGID" type="12" table="HIS_MMS_MZFYZB" />
<f name="HZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="JZPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="MZFPPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="ZDZBPKEY" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYR" type="12" table="HIS_MMS_MZFYZB" />
<f name="PYRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="SHR" type="12" table="HIS_MMS_MZFYZB" />
<f name="SHRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="FYR" type="12" table="HIS_MMS_MZFYZB" />
<f name="FYRQ" type="93" table="HIS_MMS_MZFYZB" />
<f name="LOCKFLAG" type="-5" table="HIS_MMS_MZFYZB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMztyHzcfDao" log="true" type="1" memo="门诊退费退耗材通过患者处方进行退费的dao">
<sql>select a.cfh,a.PKEY FYBPKEY,a.CJRQ FYRQ,c.pkey MZFPPKEY,b.HZPKEY,b.JZPKEY,b.pkey ZDZBPKEY from HIS_MMS_MZFYZB a left join HIS_SFZD_ZB b on b.JZZDPKEY=a.ZDZBPKEY and a.JGID=b.JGID left join HIS_MZJS_MZFPZB c on b.PKEY=c.GLZDBPKEY and b.JGID=c.JGID where b.JSZT=1 and b.ISHC=0 and a.JGID=? and a.HZPKEY=? order by a.CJRQ desc </sql>
<fields>
<f name="CFH" type="12" />
<f name="FYBPKEY" type="12" />
<f name="FYRQ" type="93" />
<f name="MZFPPKEY" type="12"/>
<f name="HZPKEY" type="12"/>
<f name="JZPKEY" type="12"/>
<f name="ZDZBPKEY" type="12"/>
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMztftySqdDao" log="true" type="1" memo="门诊退费退耗材通过患者退费申请单进行退费的dao">
<sql>
select * from (select a.MZFPPKEY,a.SQZT,a.SQRY,a.SQRQ,a.SHZT,a.SHRY,a.SHRQ,a.ZXZT,a.ZXRY,a.ZXRQ,a.CJR,a.CJRQ,a.JGID,a.SHBHBZ,a.TFYY,a.HZPKEY,a.JZPKEY,a.ZDZBPKEY,c.PKEY FYBPKEY,c.cfh,(select sum(tfsl) from HIS_SFZD_YZMXB where JGID=a.JGID and cfh=c.cfh) tfsl,a.LOCKFLAG from HIS_MZJS_MZFPCHSQ a left join HIS_SFZD_ZB b on a.ZDZBPKEY=b.PKEY and a.JGID=b.JGID left join HIS_MMS_MZFYZB c on b.JZZDPKEY=c.ZDZBPKEY where a.JGID=? and (1=? or c.FYYF=?) and a.ZXZT=0 and a.HZPKEY=? order by a.SQRQ desc) where tfsl > 0
</sql>
<tables>
<table name="HIS_MZJS_MZFPCHSQ" insert="true" update="true" delete="true">
<primary>MZFPPKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="MZFPPKEY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SQZT" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SQRY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SQRQ" type="93" table="HIS_MZJS_MZFPCHSQ" />
<f name="SHZT" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SHRY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SHRQ" type="93" table="HIS_MZJS_MZFPCHSQ" />
<f name="ZXZT" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="ZXRY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="ZXRQ" type="93" table="HIS_MZJS_MZFPCHSQ" />
<f name="CJR" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="CJRQ" type="93" table="HIS_MZJS_MZFPCHSQ" />
<f name="JGID" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="SHBHBZ" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="TFYY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="HZPKEY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="JZPKEY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="ZDZBPKEY" type="12" table="HIS_MZJS_MZFPCHSQ" />
<f name="FYBPKEY" type="12" />
<f name="CFH" type="12" />
<f name="TFSL" type="8" />
<f name="LOCKFLAG" type="-5" table="HIS_MZJS_MZFPCHSQ" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMztyDqdjYjtyDao" log="true" type="1" memo="当前需退费账单关联的退耗材数量dao">
<sql>select a.YZX,a.YZMX,a.TYKS,a.TYSL from HIS_MMS_MZTYMXB a left join HIS_MMS_MZTYZB b on a.TYBPKEY=b.pkey and a.JGID=b.JGID where b.ISCX=0 AND b.JGID=? and b.ZDZBPKEY=?</sql>
<fields>
<f name="YZX" type="12" />
<f name="YZMX" type="12" />
<f name="TYKS" type="12" />
<f name="TYSL" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzFycxMainDao" log="true" type="1" memo="门诊发放耗材查询主dao">
<sql><![CDATA[
select distinct a.YZLX,a.HZPKEY,a.JZPKEY,a.JZH,a.CFH,a.YZSHZT,nvl(a.YZSFZT,0) YZSFZT,a.JGID,a.YZLB,b.jjks,c.xm,zdb.JBMC,f.JSSJ,fyzb.fyyf FYKS,sum((nvl(a.YZSL,0)-nvl(a.YZTFSL,0))*a.YZDJ) yzje ,fyzb.fyrq fysj ,fyzb.FYYF,fyzb.PYR,fyzb.fyr
from HIS_YZ_MXB a left join HIS_JZ_BASEINFO b on a.jzpkey=b.pkey and a.JGID=b.JGID left join HIS_HZINFO c on a.hzpkey=c.pkey and a.JGID=c.JGID left join HIS_JZ_MZZD zdb on a.hzpkey=zdb.hzpkey and a.jzpkey=zdb.jzpkey and a.JGID=zdb.JGID and zdb.SFZZD=1 left join HIS_SFZD_YZMXB e on a.pkey=e.yzmx and a.JGID=e.JGID left join HIS_SFZD_ZB f on e.ZDZBPKEY=f.pkey and e.JGID=f.JGID left join HIS_MMS_MZFYZB fyzb on fyzb.ZDZBPKEY=f.pkey and fyzb.JGID=f.JGID and fyzb.FYZT=1
where a.JGID=? and a.GLLX='W' and (b.JZLX='M' or b.JZLX='J') and a.YZSHZT='1' and f.ishc=0 and f.JSZT=1 #fyzt# #jjks# and fyzb.FYRQ >= ? and fyzb.FYRQ <=? group by a.HZPKEY,a.JZPKEY,a.JZH,a.CFH,a.YZSHZT,a.YZSFZT,a.JGID,a.YZLB,a.YZLX,b.jjks,c.xm,zdb.JBMC,f.JSSJ,fyzb.fyyf,fyzb.fyrq,fyzb.FYYF,fyzb.PYR,fyzb.fyr order by a.CFH
]]></sql>
<fields>
<f name="YZLX" type="12" />
<f name="HZPKEY" type="12" />
<f name="JZPKEY" type="12" />
<f name="JZH" type="12" />
<f name="CFH" type="12" />
<f name="YZSHZT" type="12" />
<f name="YZSFZT" type="12" />
<f name="JGID" type="12" />
<f name="YZLB" type="12" />
<f name="JJKS" type="12" />
<f name="XM" type="12" />
<f name="JBMC" type="12" />
<f name="JSSJ" type="93" />
<f name="FYKS" type="12" />
<f name="YZJE" type="4" />
<f name="FYSJ" type="93" />
<f name="FYYF" type="12" />
<f name="PYR" type="12" />
<f name="FYR" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsMzfycxFyKclsDao" log="true" type="1" memo="门诊发耗材查询的发耗材库存流水">
<sql>select PKEY,YZX,YZMX,YZDJ,YZSL,FYBPKEY,HZBQ,HZKS,FYKS,HZPKEY,YPFL,JZPKEY,TYPE,YZDL,TYSL,CJR,CJRQ,XGR,XGRQ,JGID,KSKCPKEY,KSKCPCPKEY from HIS_MMS_MZFYMXB where JGID=? and hzpkey=? and jzpkey=? and YZMX=? order by CJRQ</sql>
<fields>
<f name="PKEY" type="12" />
<f name="YZX" type="12" />
<f name="YZMX" type="12" />
<f name="YZDJ" type="12" />
<f name="YZSL" type="12" />
<f name="FYBPKEY" type="12" />
<f name="HZBQ" type="12" />
<f name="HZKS" type="12" />
<f name="FYKS" type="12" />
<f name="HZPKEY" type="12" />
<f name="YPFL" type="12" />
<f name="JZPKEY" type="12" />
<f name="TYPE" type="12" />
<f name="YZDL" type="12" />
<f name="TYSL" type="12" />
<f name="CJR" type="12" />
<f name="CJRQ" type="93" />
<f name="XGR" type="12" />
<f name="XGRQ" type="93" />
<f name="JGID" type="12" />
<f name="KSKCPKEY" type="12" />
<f name="KSKCPCPKEY" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsMzfycxTyKclsDao" log="true" type="1" memo="门诊发耗材查询耗材退库流水dao">
<sql>select PKEY,YZX,YZMX,YZDJ,TYSL,HZBQ,HZKS,TYKS,HZPKEY,YPFL,JZPKEY,TYBPKEY,TYPE,KSKCPKEY,KSKCPCPKEY,CJR,CJRQ,XGR,XGRQ,JGID,MZFYMXBPKEY,PYBPKEY,TYDH,TYYY,BED,CFH,ZYNO from HIS_MMS_MZTYMXB where JGID=? and hzpkey=? and jzpkey=? and YZMX=? order by CJRQ</sql>
<fields>
<f name="PKEY" type="12" />
<f name="YZX" type="12" />
<f name="YZMX" type="12" />
<f name="YZDJ" type="12" />
<f name="TYSL" type="12" />
<f name="HZBQ" type="12" />
<f name="HZKS" type="12" />
<f name="TYKS" type="12" />
<f name="HZPKEY" type="12" />
<f name="YPFL" type="12" />
<f name="JZPKEY" type="12" />
<f name="TYBPKEY" type="12" />
<f name="TYPE" type="12" />
<f name="KSKCPKEY" type="12" />
<f name="KSKCPCPKEY" type="12" />
<f name="CJR" type="12" />
<f name="CJRQ" type="93" />
<f name="XGR" type="12" />
<f name="XGRQ" type="93" />
<f name="JGID" type="12" />
<f name="MZFYMXBPKEY" type="12" />
<f name="PYBPKEY" type="12" />
<f name="TYDH" type="12" />
<f name="TYYY" type="12" />
<f name="BED" type="12" />
<f name="CFH" type="12" />
<f name="ZYNO" type="12" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="zyyffhchzDao" log="true" type="1" memo="住院耗材发放汇总dao">
<sql><![CDATA[
select yzx,ward,YZMC,sum(jzyzsl) sl,YPYZJBDW,YPYZJBJG,sum(JE) zje,YZJX,'' glmx,wzgg,YPFL,YZLX,YZZCYFS,dwview,wzcs,fyks,bm from (select a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL,a.DFYPKEY,a.FYMXPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.YZDL,a.TYSL,a.SFSL,a.SFLYSH,a.SFYSSH,a.LYSHR,a.LYSHRQ,a.YSSHR,a.YSSHRQ,a.FYZT,d.ward,d.bed,d.jjys,f.xm,e.zxtime,a.yzsl*b.YZJZZHXS jzyzsl,b.YPYZJBDW,b.YZJZZHXS,b.YZMC,c.WZGG,b.YZJL,b.YZJLDW,b.YZPC,b.yzcl,e.pkey execpkey,e.SFFLAG,b.YPYZJBJG,a.yzsl*b.yzjzzhxs*b.YPYZJBJG je ,b.YZJX,b.YZLX,b.YZZCYFS,g.dwview,c.WZCS,g.bm from HIS_MMS_PYB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_MMS_WZZD c on a.YZX=c.WZBM and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on a.JZPKEY=d.pkey and a.JGID=d.JGID left join HIS_YZ_EXEC e on a.DFYPKEY=e.pkey and a.JGID=e.JGID left join HIS_HZINFO f on a.hzpkey=f.pkey and a.JGID=f.JGID LEFT JOIN HIS_SFX g on a.YZX=g.bm and a.JGID=g.JGID where #FYZT# AND a.TYPE='Z' and (d.JZLX='Z' or (d.JZLX='J' AND d.SFLG='1')) AND a.FYCX=0 and a.JGID=? and b.SFYFJJFY !='1' #ward# #yzcl# #yf# #ypfl# #ypbm# #zyno# #yplysh# and e.zxtime >=? and e.zxtime <= ? ) group by ward,YZMC,YPYZJBDW,YPYZJBJG,YZJX,wzgg,YPFL,yzx,YZLX,YZZCYFS,dwview,wzcs,fyks,bm
]]></sql>
<fields>
<f name="YZX" type="12" />
<f name="WARD" type="12" />
<f name="YZMC" type="12" />
<f name="SL" type="4" />
<f name="YPYZJBDW" type="12" />
<f name="YPYZJBJG" type="12" />
<f name="ZJE" type="4" />
<f name="YZJX" type="12" />
<f name="GLMX" type="1" />
<f name="WZGG" type="12" />
<f name="YPFL" type="12" />
<f name="YZLX" type="12" />
<f name="YZZCYFS" type="12" />
<f name="DWVIEW" type="12" />
<f name="WZCS" type="12" />
<f name="FYKS" type="12" />
<f name="BM" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="zyyffhcPybMxDao" log="true" type="1" memo="住院药房发耗材的耗材明细dao">
<sql><![CDATA[
select distinct b.cfh,d.JJKS,d.ZYNO,a.PKEY,a.YZX,a.YZMX,a.YZDJ,a.YZSL,a.DFYPKEY,a.FYMXPKEY,a.HZBQ,a.HZKS,a.FYKS,a.HZPKEY,a.YPFL,a.JZPKEY,a.TYPE,a.CJR,a.CJRQ,a.XGR,a.XGRQ,a.JGID,a.YZDL,a.TYSL,a.SFSL,a.SFLYSH,a.SFYSSH,a.LYSHR,a.LYSHRQ,a.YSSHR,a.YSSHRQ,a.FYZT,d.ward,d.bed,d.jjys,f.xm,e.zxtime,a.yzsl*b.YZJZZHXS jzyzsl,b.YPYZJBDW,b.YZJZZHXS,b.YZMC,c.WZGG,b.YZJL,b.YZJLDW,b.YZPC,b.yzcl,e.pkey execpkey,e.SFFLAG,b.YPYZJBJG,a.yzsl*b.yzjzzhxs*b.YPYZJBJG je,b.YZJX,a.SFSL*b.YZJZZHXS jzsfsl,e.zxsl,e.zxje,b.yzxpkey,b.YZXZSJ,e.ISACTION,b.YZLX,b.YZZCYFS,b.YZYF,a.FYCX,e.ZXFLAG,a.LOCKFLAG,g.dwview,h.pkey sfxpkey,g.bm,b.SFYFJJFY,b.pkey yzmxpkey from HIS_MMS_PYB a left join HIS_YZ_MXB b on a.YZMX=b.PKEY and a.JGID=b.JGID left join HIS_MMS_WZZD c on a.YZX=c.WZBM and a.JGID=c.JGID left join HIS_JZ_BASEINFO d on a.JZPKEY=d.pkey and a.JGID=d.JGID left join HIS_YZ_EXEC e on a.DFYPKEY=e.pkey and a.JGID=e.JGID left join HIS_HZINFO f on a.hzpkey=f.pkey and a.JGID=f.JGID LEFT JOIN HIS_SFX g on a.YZX=g.bm and a.JGID=g.JGID LEFT JOIN HIS_SFZD_SFXMXB h on a.YZMX=h.yzmx and e.pkey=h.EXEPKEY and (h.JSZT='1' or h.JSZT='0') and a.JGID=h.JGID where #FYZT# AND a.TYPE='Z' AND a.FYCX=0 and (d.JZLX='Z' or (d.JZLX='J' AND d.SFLG='1')) AND a.FYCX=0 and a.JGID=? and b.SFYFJJFY !='1' #ward# #yzcl# #yf# #ypfl# #ypbm# #zyno# #yplysh# and e.zxtime >=? and e.zxtime <= ?
]]></sql>
<tables>
<table name="HIS_MMS_PYB" insert="false" update="true" delete="false">
<primary>PKEY</primary>
<primary>YZMX</primary>
<primary>FYMXPKEY</primary>
<primary>FYZT</primary>
<primary>FYCX</primary>
</table>
<table name="HIS_YZ_EXEC" insert="false" update="true" delete="false">
<primary>EXECPKEY</primary>
<primary>YZMX</primary>
<primary>JZPKEY</primary>
<primary>SFFLAG</primary>
<primary>ISACTION</primary>
<primary>ZXFLAG</primary>
</table>
<table name="HIS_YZ_MXB" insert="false" update="true" delete="false">
<primary>SFYFJJFY</primary>
<primary>yzmxpkey</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="CFH" type="12" />
<f name="JJKS" type="12" />
<f name="ZYNO" type="12" />
<f name="PKEY" type="12" table="HIS_MMS_PYB" />
<f name="YZX" type="12" table="HIS_MMS_PYB" />
<f name="YZMX" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="YZDJ" type="12" table="HIS_MMS_PYB" />
<f name="YZSL" type="12" table="HIS_MMS_PYB" />
<f name="DFYPKEY" type="12" table="HIS_MMS_PYB" />
<f name="FYMXPKEY" type="12" table="HIS_MMS_PYB" />
<f name="HZBQ" type="12" table="HIS_MMS_PYB" />
<f name="HZKS" type="12" table="HIS_MMS_PYB" />
<f name="FYKS" type="12" table="HIS_MMS_PYB" />
<f name="HZPKEY" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="YPFL" type="12" table="HIS_MMS_PYB" />
<f name="JZPKEY" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="TYPE" type="12" table="HIS_MMS_PYB" />
<f name="CJR" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="CJRQ" type="93" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="XGR" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="XGRQ" type="93" table="HIS_MMS_PYB,HIS_YZ_EXEC" />
<f name="JGID" type="12" table="HIS_MMS_PYB,HIS_YZ_EXEC,HIS_YZ_MXB" />
<f name="YZDL" type="12" table="HIS_MMS_PYB" />
<f name="TYSL" type="12" table="HIS_MMS_PYB" />
<f name="SFSL" type="12" table="HIS_MMS_PYB" />
<f name="SFLYSH" type="12" table="HIS_MMS_PYB" />
<f name="SFYSSH" type="12" table="HIS_MMS_PYB" />
<f name="LYSHR" type="12" table="HIS_MMS_PYB" />
<f name="LYSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="YSSHR" type="12" table="HIS_MMS_PYB" />
<f name="YSSHRQ" type="93" table="HIS_MMS_PYB" />
<f name="FYZT" type="12" table="HIS_MMS_PYB" />
<f name="WARD" type="12" />
<f name="BED" type="12" />
<f name="JJYS" type="12" />
<f name="XM" type="12" />
<f name="ZXTIME" type="93" table="HIS_YZ_EXEC" />
<f name="JZYZSL" type="4" />
<f name="YPYZJBDW" type="12" />
<f name="YZJZZHXS" type="12" />
<f name="YZMC" type="12" table="HIS_YZ_EXEC" />
<f name="WZGG" type="12" />
<f name="YZJL" type="12" />
<f name="YZJLDW" type="12" />
<f name="YZPC" type="12" />
<f name="YZCL" type="12" />
<f name="EXECPKEY" schemaname="PKEY" type="12" table="HIS_YZ_EXEC" />
<f name="SFFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="YPYZJBJG" type="12" />
<f name="JE" type="12" />
<f name="YZJX" type="12" />
<f name="JZSFSL" type="12" />
<f name="zxsl" type="12" table="HIS_YZ_EXEC" />
<f name="zxje" type="12" table="HIS_YZ_EXEC" />
<f name="yzxpkey" type="12" />
<f name="YZXZSJ" type="93" />
<f name="ISACTION" type="12" table="HIS_YZ_EXEC" />
<f name="YZLX" type="12" />
<f name="YZZCYFS" type="12" />
<f name="YZYF" type="12" />
<f name="FYCX" type="12" table="HIS_MMS_PYB" />
<f name="ZXFLAG" type="12" table="HIS_YZ_EXEC" />
<f name="LOCKFLAG" type="12" table="HIS_MMS_PYB" />
<f name="DWVIEW" type="12" />
<f name="sfxpkey" type="12" />
<f name="BM" type="12" />
<f name="SFYFJJFY" type="12" table="HIS_YZ_MXB" />
<f name="yzmxpkey" schemaname="PKEY" type="12" table="HIS_YZ_MXB" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="mmsZyFycxMainDao" log="true" type="1" memo="住院发放耗材查询主dao">
<sql><![CDATA[
select distinct a.YZLX,a.HZPKEY,a.JZPKEY,b.zyno,a.CFH,a.YZSHZT,nvl(a.YZSFZT,0) YZSFZT,a.JGID,a.YZLB,b.jjks,c.xm,zdb.JBMC,sum((nvl(a.YZSL,0)-nvl(a.YZTFSL,0))*a.YZDJ) yzje ,fyzb.FYTIME fysj ,fyzb.FYKS,fyzb.fyr
from HIS_YZ_MXB a left join HIS_JZ_BASEINFO b on a.jzpkey=b.pkey and a.JGID=b.JGID left join HIS_HZINFO c on a.hzpkey=c.pkey and a.JGID=c.JGID left join HIS_JZ_MZZD zdb on a.hzpkey=zdb.hzpkey and a.jzpkey=zdb.jzpkey and a.JGID=zdb.JGID and zdb.SFZZD=1 left join HIS_MMS_ZYFYMXB fymx on fymx.YZMX=a.pkey and fymx.JGID=a.JGID left join HIS_MMS_ZYFYZB fyzb on fymx.FYBPKEY=fyzb.pkey and fyzb.JGID=fymx.JGID
where a.JGID=? and a.GLLX='W' and b.JZLX='Z' and a.YZSHZT='1'#fyzt# #jjks# and fyzb.FYTIME >= ? and fyzb.FYTIME <=? group by a.HZPKEY,a.JZPKEY,b.ZYNO,a.CFH,a.YZSHZT,a.YZSFZT,a.JGID,a.YZLB,a.YZLX,b.jjks,c.xm,zdb.JBMC,fyzb.FYKS,fyzb.FYTIME,fyzb.fyr order by a.CFH
]]></sql>
<fields>
<f name="YZLX" type="12" />
<f name="HZPKEY" type="12" />
<f name="JZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="CFH" type="12" />
<f name="YZSHZT" type="12" />
<f name="YZSFZT" type="12" />
<f name="JGID" type="12" />
<f name="YZLB" type="12" />
<f name="JJKS" type="12" />
<f name="XM" type="12" />
<f name="JBMC" type="12" />
<f name="YZJE" type="4" />
<f name="FYSJ" type="93" />
<f name="FYKS" type="12" />
<f name="FYR" type="12" />
</fields>
<parameter>
<p>12</p>
<p>93</p>
<p>93</p>
</parameter>
</dao>
<dao id="zycfjzdyCfmxDao" log="true" type="1" memo="住院处方明细dao">
<sql>
select PKEY,HZPKEY,JZPKEY,JZH,CFH,YZCL,YZLB,YZLX,YZXPKEY,YZSHZT,YZJL,YZJLDW,YZPC,YZTS,YZYF,YZZCYYF,YZZCYYFMS,YZTZH,YZXZSJ,YZXZYS,YZLRYS,YZJE,YZSL,YZJX,YZBEGINJDSJ,YZENDJDSJ,YZBEGINZXSJ,YZZXSJ,YZYTZSJ,YZTZSJ,YZDJ,YZBEGINJDHS,YZENDJDHS,YZTZYS,YZZT,YZFYLB,YZDAYCS,YZJDBZ,YZYX,YZZDY,YZXZSXYS,YZTZSXYS,ZYCS,YZXZRLX,YZCXR,YZCXBZ,YZCXSJ,YZCXYY,YZFYZH,YZSFZYZ,YZSCZXCS,YZZTPKEY,YZDS,YZJJBZ,CJR,CJRQ,JGID,YZLC,YZGLYZ,YZSYCS,YZZXKS,YZKZXTS,PS,PSBZ,YZFJSM,YZFB,YZSYLS,YZLSDW,YZSFPY,YZCLTM,YZCLYY,YZBZ,YZBBLX,YZDW,YZXZKS,YZZL,YZJZJLXS,YZJZZHXS,YPYZJBJG,YPYZJBDW,YPYZBZJG,YPYZBZDW,YPYZDXDW,YPYZDXSL,YPYZZHXS,YZMC,YZSFZT,YZTFSL,YZDJSL,YZYL,YZZCYFSKEY,YZZCYFS,YZZCYJX,YZZCYDJF,ISDJJS,DJJSSL,ISZCYDJCL,IZZCYDJFJF,ISGFFJ,YZZCYBZ,SQDTYPE,SQDPKEY,SQDJSPKEY,SQDTFJE,ZYYZFL,YZSHYS,YZSHRQ,ISZPC,YZZPC,YZPCFFSJ,YZXH,PSJG,ZCYGLCZLX,YZZFR,YZZFSJ,YZZFYY,PSJGSJ,PSJGR,ISDPBCL,HZSZKS from HIS_YZ_MXB where JGID=? and HZPKEY=? and JZPKEY=? and cfh=? and (YZLX='0' or YZLX='1' or YZLX='5' or YZLX='3') order by yzxh
</sql>
<tables>
<table name="HIS_YZ_MXB" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>HZPKEY</primary>
<primary>JZPKEY</primary>
<primary>JGID</primary>
<primary>YZSFZT</primary>
<primary>YZDJSL</primary>
<primary>YZSHZT</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_YZ_MXB" />
<f name="HZPKEY" type="12" table="HIS_YZ_MXB" />
<f name="JZPKEY" type="12" table="HIS_YZ_MXB" />
<f name="JZH" type="12" table="HIS_YZ_MXB" />
<f name="CFH" type="12" table="HIS_YZ_MXB" />
<f name="YZCL" type="12" table="HIS_YZ_MXB" />
<f name="YZLB" type="12" table="HIS_YZ_MXB" />
<f name="YZLX" type="12" table="HIS_YZ_MXB" />
<f name="YZXPKEY" type="12" table="HIS_YZ_MXB" />
<f name="YZSHZT" type="12" table="HIS_YZ_MXB" />
<f name="YZJL" type="12" table="HIS_YZ_MXB" />
<f name="YZJLDW" type="12" table="HIS_YZ_MXB" />
<f name="YZPC" type="12" table="HIS_YZ_MXB" />
<f name="YZTS" type="12" table="HIS_YZ_MXB" />
<f name="YZYF" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYYF" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYYFMS" type="12" table="HIS_YZ_MXB" />
<f name="YZTZH" type="12" table="HIS_YZ_MXB" />
<f name="YZXZSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZXZYS" type="12" table="HIS_YZ_MXB" />
<f name="YZLRYS" type="12" table="HIS_YZ_MXB" />
<f name="YZJE" type="12" table="HIS_YZ_MXB" />
<f name="YZSL" type="12" table="HIS_YZ_MXB" />
<f name="YZJX" type="12" table="HIS_YZ_MXB" />
<f name="YZBEGINJDSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZENDJDSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZBEGINZXSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZZXSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZYTZSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZTZSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZDJ" type="12" table="HIS_YZ_MXB" />
<f name="YZBEGINJDHS" type="12" table="HIS_YZ_MXB" />
<f name="YZENDJDHS" type="12" table="HIS_YZ_MXB" />
<f name="YZTZYS" type="12" table="HIS_YZ_MXB" />
<f name="YZZT" type="12" table="HIS_YZ_MXB" />
<f name="YZFYLB" type="12" table="HIS_YZ_MXB" />
<f name="YZDAYCS" type="12" table="HIS_YZ_MXB" />
<f name="YZJDBZ" type="12" table="HIS_YZ_MXB" />
<f name="YZYX" type="12" table="HIS_YZ_MXB" />
<f name="YZZDY" type="12" table="HIS_YZ_MXB" />
<f name="YZXZSXYS" type="12" table="HIS_YZ_MXB" />
<f name="YZTZSXYS" type="12" table="HIS_YZ_MXB" />
<f name="ZYCS" type="12" table="HIS_YZ_MXB" />
<f name="YZXZRLX" type="12" table="HIS_YZ_MXB" />
<f name="YZCXR" type="12" table="HIS_YZ_MXB" />
<f name="YZCXBZ" type="12" table="HIS_YZ_MXB" />
<f name="YZCXSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZCXYY" type="12" table="HIS_YZ_MXB" />
<f name="YZFYZH" type="12" table="HIS_YZ_MXB" />
<f name="YZSFZYZ" type="12" table="HIS_YZ_MXB" />
<f name="YZSCZXCS" type="12" table="HIS_YZ_MXB" />
<f name="YZZTPKEY" type="12" table="HIS_YZ_MXB" />
<f name="YZDS" type="12" table="HIS_YZ_MXB" />
<f name="YZJJBZ" type="12" table="HIS_YZ_MXB" />
<f name="CJR" type="12" table="HIS_YZ_MXB" />
<f name="CJRQ" type="93" table="HIS_YZ_MXB" />
<f name="JGID" type="12" table="HIS_YZ_MXB" />
<f name="YZLC" type="12" table="HIS_YZ_MXB" />
<f name="YZGLYZ" type="12" table="HIS_YZ_MXB" />
<f name="YZSYCS" type="12" table="HIS_YZ_MXB" />
<f name="YZZXKS" type="12" table="HIS_YZ_MXB" />
<f name="YZKZXTS" type="12" table="HIS_YZ_MXB" />
<f name="PS" type="12" table="HIS_YZ_MXB" />
<f name="PSBZ" type="12" table="HIS_YZ_MXB" />
<f name="YZFJSM" type="12" table="HIS_YZ_MXB" />
<f name="YZFB" type="12" table="HIS_YZ_MXB" />
<f name="YZSYLS" type="12" table="HIS_YZ_MXB" />
<f name="YZLSDW" type="12" table="HIS_YZ_MXB" />
<f name="YZSFPY" type="12" table="HIS_YZ_MXB" />
<f name="YZCLTM" type="12" table="HIS_YZ_MXB" />
<f name="YZCLYY" type="12" table="HIS_YZ_MXB" />
<f name="YZBZ" type="12" table="HIS_YZ_MXB" />
<f name="YZBBLX" type="12" table="HIS_YZ_MXB" />
<f name="YZDW" type="12" table="HIS_YZ_MXB" />
<f name="YZXZKS" type="12" table="HIS_YZ_MXB" />
<f name="YZZL" type="12" table="HIS_YZ_MXB" />
<f name="YZJZJLXS" type="12" table="HIS_YZ_MXB" />
<f name="YZJZZHXS" type="12" table="HIS_YZ_MXB" />
<f name="YPYZJBJG" type="12" table="HIS_YZ_MXB" />
<f name="YPYZJBDW" type="12" table="HIS_YZ_MXB" />
<f name="YPYZBZJG" type="12" table="HIS_YZ_MXB" />
<f name="YPYZBZDW" type="12" table="HIS_YZ_MXB" />
<f name="YPYZDXDW" type="12" table="HIS_YZ_MXB" />
<f name="YPYZDXSL" type="12" table="HIS_YZ_MXB" />
<f name="YPYZZHXS" type="12" table="HIS_YZ_MXB" />
<f name="YZMC" type="12" table="HIS_YZ_MXB" />
<f name="YZSFZT" type="12" table="HIS_YZ_MXB" />
<f name="YZTFSL" type="12" table="HIS_YZ_MXB" />
<f name="YZDJSL" type="12" table="HIS_YZ_MXB" />
<f name="YZYL" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYFSKEY" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYFS" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYJX" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYDJF" type="12" table="HIS_YZ_MXB" />
<f name="ISDJJS" type="12" table="HIS_YZ_MXB" />
<f name="DJJSSL" type="12" table="HIS_YZ_MXB" />
<f name="ISZCYDJCL" type="12" table="HIS_YZ_MXB" />
<f name="IZZCYDJFJF" type="12" table="HIS_YZ_MXB" />
<f name="ISGFFJ" type="12" table="HIS_YZ_MXB" />
<f name="YZZCYBZ" type="12" table="HIS_YZ_MXB" />
<f name="SQDTYPE" type="12" table="HIS_YZ_MXB" />
<f name="SQDPKEY" type="12" table="HIS_YZ_MXB" />
<f name="SQDJSPKEY" type="12" table="HIS_YZ_MXB" />
<f name="SQDTFJE" type="12" table="HIS_YZ_MXB" />
<f name="ZYYZFL" type="12" table="HIS_YZ_MXB" />
<f name="YZSHYS" type="12" table="HIS_YZ_MXB" />
<f name="YZSHRQ" type="93" table="HIS_YZ_MXB" />
<f name="ISZPC" type="12" table="HIS_YZ_MXB" />
<f name="YZZPC" type="12" table="HIS_YZ_MXB" />
<f name="YZPCFFSJ" type="12" table="HIS_YZ_MXB" />
<f name="YZXH" type="8" table="HIS_YZ_MXB" />
<f name="PSJG" type="12" table="HIS_YZ_MXB" />
<f name="ZCYGLCZLX" type="12" table="HIS_YZ_MXB" />
<f name="YZZFR" type="12" table="HIS_YZ_MXB" />
<f name="YZZFSJ" type="93" table="HIS_YZ_MXB" />
<f name="YZZFYY" type="12" table="HIS_YZ_MXB" />
<f name="PSJGSJ" type="93" table="HIS_YZ_MXB" />
<f name="PSJGR" type="12" table="HIS_YZ_MXB" />
<f name="ISDPBCL" type="12" table="HIS_YZ_MXB" />
<f name="HZSZKS" type="12" table="HIS_YZ_MXB" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="mmsZyfycxFyKclsDao" log="true" type="1" memo="住院发耗材查询的发耗材库存流水">
<sql>
select PKEY,FYBPKEY,JZPKEY,HZPKEY,ZYNO,CFH,PYBPKEY,YZXPKEY,YZMX,YZDJ,YZSL,BED,YPFL,YZDL,TYSL,KSKCPKEY,KSKCPCPKEY,CJR,CJRQ,XGR,XGRQ,JGID,EXEPKEY,LOCKFLAG from HIS_MMS_ZYFYMXB where JGID=? and hzpkey=? and jzpkey=? and YZMX=? order by CJRQ
</sql>
<fields>
<f name="PKEY" type="12" />
<f name="FYBPKEY" type="12" />
<f name="JZPKEY" type="12" />
<f name="HZPKEY" type="12" />
<f name="ZYNO" type="12" />
<f name="CFH" type="12" />
<f name="PYBPKEY" type="12" />
<f name="YZXPKEY" type="12" />
<f name="YZMX" type="12" />
<f name="YZDJ" type="12" />
<f name="YZSL" type="12" />
<f name="BED" type="12" />
<f name="YPFL" type="12" />
<f name="YZDL" type="12" />
<f name="TYSL" type="12" />
<f name="KSKCPKEY" type="12" />
<f name="KSKCPCPKEY" type="12" />
<f name="CJR" type="12" />
<f name="CJRQ" type="93" />
<f name="XGR" type="12" />
<f name="XGRQ" type="93" />
<f name="JGID" type="12" />
<f name="EXEPKEY" type="12" />
<f name="LOCKFLAG" type="-5" />
</fields>
<parameter>
<p>12</p>
<p>12</p>
<p>12</p>
<p>12</p>
</parameter>
</dao>
<dao id="zyfhcbydjhDao" log="true" type="1" memo="用于住院发耗材按住院登记号进行处理,不考虑患者是否在院dao">
<sql>
select a.PKEY,a.HZPKEY,a.GHPKEY,a.JZLX,a.JZZT,a.JZZB,a.HZFB,a.JZJS,a.ISYB,a.ISZZ,a.YYLX,a.ISLG,a.ISGSSJJ,a.HZYBLX,a.JJKS,a.JJRQ,a.JJYS,a.FBRQ,a.ZYNUM,a.WARD,a.ROOM,a.BED,a.KZRQ,a.JSRQ,a.THRY,a.HDYY,a.HDRQ,a.MZNUM,a.CJR,a.CJRQ,a.JGID,a.JZNO,a.MZNO,a.ZYNO,a.JZKH,a.CARDPKEY,a.JZNL,a.ISJZ,a.ZYLX,a.ZYHZLY,a.ZYYYRQ,a.CYRQ,a.CYYS,a.ZYNOOLD,a.SCZYRQ,a.ISGL,a.ISSJ,a.HZLX,a.GRLX,a.QTGRLX,a.CWFJLX,a.YSLX,a.MQJZINFO,a.ZKRQ,a.RYTJ,a.RYBQ,a.RYJZINFO,a.RYYS,a.RYQK,a.JZZL,a.JYYJ,a.ZYBZ,a.RYZD,a.RYZDMS,a.ZYBAH,a.RYNL,a.RYXSENLD,a.RYXSENLH,a.RYXSENLS,a.ZYZH,a.JZKLX,a.CRFS,a.OTHERCRFS,a.MAINBLYS,a.MAINBLXS,a.MOTHERJZPKEY,a.ZKDATE,a.RQDATE,a.CYKS,a.CYWARD,a.CYBED,b.xm,b.xb from HIS_JZ_BASEINFO a left join HIS_HZINFO b on a.hzpkey=b.pkey and a.JGID=b.JGID where (a.JZLX='Z' or (a.JZLX='J' AND a.SFLG='1')) and a.JGID=?
</sql>
<tables>
<table name="HIS_JZ_BASEINFO" insert="true" update="true" delete="true">
<primary>PKEY</primary>
<primary>HZPKEY</primary>
<primary>JGID</primary>
</table>
</tables>
<fields>
<f name="PKEY" type="12" table="HIS_JZ_BASEINFO" />
<f name="HZPKEY" type="12" table="HIS_JZ_BASEINFO" />
<f name="GHPKEY" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZZT" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZZB" type="12" table="HIS_JZ_BASEINFO" />
<f name="HZFB" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZJS" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISYB" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISZZ" type="12" table="HIS_JZ_BASEINFO" />
<f name="YYLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISLG" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISGSSJJ" type="12" table="HIS_JZ_BASEINFO" />
<f name="HZYBLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="JJKS" type="12" table="HIS_JZ_BASEINFO" />
<f name="JJRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="JJYS" type="12" table="HIS_JZ_BASEINFO" />
<f name="FBRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="ZYNUM" type="8" table="HIS_JZ_BASEINFO" />
<f name="WARD" type="12" table="HIS_JZ_BASEINFO" />
<f name="ROOM" type="12" table="HIS_JZ_BASEINFO" />
<f name="BED" type="12" table="HIS_JZ_BASEINFO" />
<f name="KZRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="JSRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="THRY" type="12" table="HIS_JZ_BASEINFO" />
<f name="HDYY" type="12" table="HIS_JZ_BASEINFO" />
<f name="HDRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="MZNUM" type="8" table="HIS_JZ_BASEINFO" />
<f name="CJR" type="12" table="HIS_JZ_BASEINFO" />
<f name="CJRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="JGID" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZNO" type="12" table="HIS_JZ_BASEINFO" />
<f name="MZNO" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYNO" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZKH" type="12" table="HIS_JZ_BASEINFO" />
<f name="CARDPKEY" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZNL" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISJZ" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYHZLY" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYYYRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="CYRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="CYYS" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYNOOLD" type="12" table="HIS_JZ_BASEINFO" />
<f name="SCZYRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="ISGL" type="12" table="HIS_JZ_BASEINFO" />
<f name="ISSJ" type="12" table="HIS_JZ_BASEINFO" />
<f name="HZLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="GRLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="QTGRLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="CWFJLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="YSLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="MQJZINFO" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZKRQ" type="93" table="HIS_JZ_BASEINFO" />
<f name="RYTJ" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYBQ" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYJZINFO" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYYS" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYQK" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZZL" type="12" table="HIS_JZ_BASEINFO" />
<f name="JYYJ" type="-5" table="HIS_JZ_BASEINFO" />
<f name="ZYBZ" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYZD" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYZDMS" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZYBAH" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYNL" type="12" table="HIS_JZ_BASEINFO" />
<f name="RYXSENLD" type="-5" table="HIS_JZ_BASEINFO" />
<f name="RYXSENLH" type="-5" table="HIS_JZ_BASEINFO" />
<f name="RYXSENLS" type="-5" table="HIS_JZ_BASEINFO" />
<f name="ZYZH" type="12" table="HIS_JZ_BASEINFO" />
<f name="JZKLX" type="12" table="HIS_JZ_BASEINFO" />
<f name="CRFS" type="12" table="HIS_JZ_BASEINFO" />
<f name="OTHERCRFS" type="12" table="HIS_JZ_BASEINFO" />
<f name="MAINBLYS" type="12" table="HIS_JZ_BASEINFO" />
<f name="MAINBLXS" type="12" table="HIS_JZ_BASEINFO" />
<f name="MOTHERJZPKEY" type="12" table="HIS_JZ_BASEINFO" />
<f name="ZKDATE" type="93" table="HIS_JZ_BASEINFO" />
<f name="RQDATE" type="93" table="HIS_JZ_BASEINFO" />
<f name="CYKS" type="12" table="HIS_JZ_BASEINFO" />
<f name="CYWARD" type="12" table="HIS_JZ_BASEINFO" />
<f name="CYBED" type="12" table="HIS_JZ_BASEINFO" />
<f name="XM" type="12" />
<f name="XB" type="12" />
</fields>
<parameter>
<p>12</p>
</parameter>
</dao>
</datasource>