给单据接口增加有无欠款的筛选
This commit is contained in:
@@ -134,6 +134,12 @@
|
||||
<bind name="bindAccountId" value="'%'+accountId+'%'"/>
|
||||
and (dh.account_id=#{accountId} or dh.account_id_list like #{bindAccountId})
|
||||
</if>
|
||||
<if test="hasDebt != null and hasDebt ==1">
|
||||
and (ifnull(dh.discount_last_money,0)+ifnull(dh.other_money,0)-ifnull(dh.deposit,0)-abs(ifnull(dh.change_amount,0))>0)
|
||||
</if>
|
||||
<if test="hasDebt != null and hasDebt ==0">
|
||||
and (ifnull(dh.discount_last_money,0)+ifnull(dh.other_money,0)-ifnull(dh.deposit,0)-abs(ifnull(dh.change_amount,0))=0)
|
||||
</if>
|
||||
<if test="remark != null and remark !=''">
|
||||
<bind name="bindRemark" value="'%'+remark+'%'"/>
|
||||
and (dh.remark like #{bindRemark} or di.remark like #{bindRemark})
|
||||
@@ -224,6 +230,12 @@
|
||||
<bind name="bindAccountId" value="'%'+accountId+'%'"/>
|
||||
and (dh.account_id=#{accountId} or dh.account_id_list like #{bindAccountId})
|
||||
</if>
|
||||
<if test="hasDebt != null and hasDebt ==1">
|
||||
and (ifnull(dh.discount_last_money,0)+ifnull(dh.other_money,0)-ifnull(dh.deposit,0)-abs(ifnull(dh.change_amount,0))>0)
|
||||
</if>
|
||||
<if test="hasDebt != null and hasDebt ==0">
|
||||
and (ifnull(dh.discount_last_money,0)+ifnull(dh.other_money,0)-ifnull(dh.deposit,0)-abs(ifnull(dh.change_amount,0))=0)
|
||||
</if>
|
||||
<if test="remark != null and remark !=''">
|
||||
<bind name="bindRemark" value="'%'+remark+'%'"/>
|
||||
and (dh.remark like #{bindRemark} or di.remark like #{bindRemark})
|
||||
|
||||
Reference in New Issue
Block a user