update:his账单明细查询页面

This commit is contained in:
Yuan
2025-08-21 10:27:12 +08:00
parent b636852ad7
commit e31c2d8719
2 changed files with 43 additions and 53 deletions

View File

@@ -153,10 +153,6 @@ public class HISGetDataMethodByJH {
//数据类型 1-门诊 2-住院 无需修改
String payMethod = StringDUtil.changeNullToEmpty(hisBillHashMap.get("visitzOrg"));
// 添加调试日志查看payMethod的值和来源
log.info("患者: {}, 从visitzOrg获取的payMethod值: {}",
StringDUtil.changeNullToEmpty(hisBillHashMap.get("patientName")), payMethod);
//业务类型 0发病历1办卡2就诊卡充值3当日挂号-3 挂号退费4门诊缴费-4 单据退费5现场预约-5 预约退费6预约取号7住院缴费-7出院结算退费-77 预存作废退费
String bizType = StringDUtil.changeNullToEmpty(hisBillHashMap.get("bizType"));
@@ -211,10 +207,6 @@ public class HISGetDataMethodByJH {
addMap.put("patientName",patientName);
addMap.put("trade_date",thistrade_date);
addMap.put("his_wsdl_id",his_wsdl_id);
//新增HisTransId字段使用ReceiptNO
String hisTransId = StringDUtil.changeNullToEmpty(hisBillHashMap.get("receiptNO"));
addMap.put("hisTransId", hisTransId);
//如果是现金记录先放进现金集合内
if (cash_code.equals(payType)){
@@ -252,7 +244,6 @@ public class HISGetDataMethodByJH {
addMap.put("patientName","");
addMap.put("trade_date",trade_date);
addMap.put("his_wsdl_id",his_wsdl_id);
addMap.put("hisTransId",""); // 现金记录HisTransId为空
cashMap.put(hisOperCode+"_"+payMethod,addMap);
}else {
@@ -294,7 +285,6 @@ public class HISGetDataMethodByJH {
addMap.put("patientName","");
addMap.put("trade_date",trade_date);
addMap.put("his_wsdl_id",his_wsdl_id);
addMap.put("hisTransId",""); // 支票记录HisTransId为空
zhipiaoMap.put(hisOperCode+"_"+payMethod,addMap);
}else {

View File

@@ -41,42 +41,42 @@
</insert>
<select id="findBankbillHistoryList" parameterType="HashMap" resultType="HashMap">
select I_JYRQ
,I_JYSJ
,I_JZRQ
,I_YHLSH
,I_SHLSH
,I_DDH
,I_DDZT
,I_FKFZH
,I_FKFHM
,I_DDJE
,I_JYJE
,I_SXF
,I_JSJE
,I_GTDM
,I_FXK
,I_ZFKZ
,I_JYLX
,I_QS
select C_JYRQ
,C_JYSJ
,C_QSRQ
,C_LSH
,C_SHDDH
,C_YSDDH
,C_JYLX
,C_CARD
,C_FKH
,C_JYJE
,C_QSJE
,C_SXF
,C_SJZFJE
,C_ZDH
,C_ZFFS
,C_KLX
,C_JYLX
,C_FQQS
from bankbills_history
from bankbill_history
<where>
<if test="startTime!=null and startTime!=''">
and I_JYRQ &gt;= #{startTime}
and C_JYRQ &gt;= #{startTime}
</if>
<if test="endTime!=null and endTime!=''">
and I_JYRQ &lt;= #{endTime}
and C_JYRQ &lt;= #{endTime}
</if>
<if test="c_zffs!=null and c_zffs!=''">
and I_FXK = #{c_zffs}
and C_ZFFS = #{c_zffs}
</if>
<if test="likeFiled!=null and likeFiled!=''">
and I_DDH like concat('%',concat(#{likeFiled},'%'))
and C_YSDDH like concat('%',concat(#{likeFiled},'%'))
</if>
</where>
order by I_JYRQ,I_JYSJ
order by C_JYRQ,C_JYSJ
</select>
<!--获取支付方式 -->
@@ -195,24 +195,24 @@
<!--交易次数 此处查交易类型为收款的,也就是即使这笔交易退款也算交易次数-->
<select id="findBankBillNumByTime" parameterType="HashMap" resultType="HashMap">
select I_JYRQ, I_FXK, count(1) as num
from bankbills_history
where I_JYRQ &gt;= #{startTime}
and I_JYRQ &lt;= #{endTime}
and I_JYLX = '1'
group by I_FXK, I_JYRQ
order by I_FXK, I_JYRQ
select C_JYRQ, C_ZFFS, count(1) as num
from bankbill_history
where C_JYRQ &gt;= #{startTime}
and C_JYRQ &lt;= #{endTime}
and C_JYLX = '1'
group by C_ZFFS, C_JYRQ
order by C_ZFFS, C_JYRQ
</select>
<!-- 交易金额 此处统计所有数据计算金额 因为存在退款是退余额的情况 -->
<select id="findBankBillMoneyByTime" parameterType="HashMap" resultType="HashMap">
select I_JYRQ, I_FXK, sum(cast(I_JYJE as decimal(18, 2))) as money
from bankbills_history
where I_JYRQ &gt;= #{startTime}
and I_JYRQ &lt;= #{endTime}
select C_JYRQ, C_ZFFS, sum(cast(C_JYJE as decimal(18, 2))) as money
from bankbill_history
where C_JYRQ &gt;= #{startTime}
and C_JYRQ &lt;= #{endTime}
group by I_FXK, I_JYRQ
order by I_FXK, I_JYRQ
group by C_ZFFS, C_JYRQ
order by C_ZFFS, C_JYRQ
</select>
<select id="findbankbillHistoryCount" parameterType="HashMap" resultType="HashMap">
@@ -249,20 +249,20 @@
</delete>
<select id="findBankbillCountData" parameterType="HashMap" resultType="HashMap">
select count(1) as num,cast(IFNULL(sum(I_JYJE),0) as decimal(19,2)) as money
from bankbills_history
select count(1) as num,cast(IFNULL(sum(C_JYJE),0) as decimal(19,2)) as money
from bankbill_history
<where>
<if test="startTime!=null and startTime!=''">
and I_JYRQ &gt;= #{startTime}
and C_JYRQ &gt;= #{startTime}
</if>
<if test="endTime!=null and endTime!=''">
and I_JYRQ &lt;= #{endTime}
and C_JYRQ &lt;= #{endTime}
</if>
<if test="c_zffs!=null and c_zffs!=''">
and I_FXK = #{c_zffs}
and C_ZFFS = #{c_zffs}
</if>
<if test="likeFiled!=null and likeFiled!=''">
and I_DDH like concat('%',concat(#{likeFiled},'%'))
and C_YSDDH like concat('%',concat(#{likeFiled},'%'))
</if>
</where>
</select>