insert into pay_fee_detail_month(
detail_month,detail_year,detail_id,receivable_amount,discount_amount,remark,received_amount,community_id,fee_id,month_id
) values (
#{detailMonth},#{detailYear},#{detailId},#{receivableAmount},#{discountAmount},#{remark},#{receivedAmount},#{communityId},#{feeId},#{monthId}
)
insert into pay_fee_detail_month(
detail_month,detail_year,detail_id,receivable_amount,discount_amount,remark,received_amount,community_id,fee_id,month_id
) values
(
#{item.detailMonth},#{item.detailYear},#{item.detailId},#{item.receivableAmount},#{item.discountAmount},
#{item.remark},#{item.receivedAmount},#{item.communityId},#{item.feeId},#{item.monthId}
)
update pay_fee_detail_month t set t.status_cd = #{statusCd}
,t.b_id = #{newBId}
, t.detail_month= #{detailMonth}
, t.detail_year= #{detailYear}
, t.detail_id= #{detailId}
, t.receivable_amount= #{receivableAmount}
, t.discount_amount= #{discountAmount}
, t.remark= #{remark}
, t.received_amount= #{receivedAmount}
, t.community_id= #{communityId}
, t.fee_id= #{feeId}
where 1=1
and t.month_id= #{monthId}