修正异常账户规则金额口径并补充后端验证记录

This commit is contained in:
wkc
2026-03-31 16:46:05 +08:00
parent d01362cc72
commit bfac1f10d2
2 changed files with 67 additions and 7 deletions

View File

@@ -1229,8 +1229,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
ai.account_no AS accountNo,
ai.invalid_date AS invalidDate,
max(tx.txDate) AS lastTxDate,
round(sum(tx.tradeAmount), 2) AS windowTotalAmount,
round(max(tx.tradeAmount), 2) AS windowMaxSingleAmount
round(sum(tx.tradeTotalAmount), 2) AS windowTotalAmount,
round(max(tx.tradeMaxSingleAmount), 2) AS windowMaxSingleAmount
from ccdi_account_info ai
inner join ccdi_base_staff staff
on staff.id_card = ai.owner_id
@@ -1241,7 +1241,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
STR_TO_DATE(LEFT(TRIM(bs.TRX_DATE), 19), '%Y-%m-%d %H:%i:%s'),
STR_TO_DATE(LEFT(TRIM(bs.TRX_DATE), 10), '%Y-%m-%d')
) AS txDate,
GREATEST(IFNULL(bs.AMOUNT_DR, 0), IFNULL(bs.AMOUNT_CR, 0)) AS tradeAmount
IFNULL(bs.AMOUNT_DR, 0) + IFNULL(bs.AMOUNT_CR, 0) AS tradeTotalAmount,
GREATEST(IFNULL(bs.AMOUNT_DR, 0), IFNULL(bs.AMOUNT_CR, 0)) AS tradeMaxSingleAmount
from ccdi_bank_statement bs
where bs.project_id = #{projectId}
and trim(IFNULL(bs.LE_ACCOUNT_NO, '')) != ''