insert into business_pay_fee_attrs(
attr_id,operate,spec_cd,community_id,b_id,fee_id,value
) values (
#{attrId},#{operate},#{specCd},#{communityId},#{bId},#{feeId},#{value}
)
insert into pay_fee_attrs(
attr_id,spec_cd,status_cd,community_id,b_id,fee_id,value
) select t.attr_id,t.spec_cd,'0',t.community_id,t.b_id,t.fee_id,t.value from business_pay_fee_attrs t where 1=1
and t.attr_id= #{attrId}
and t.operate= 'ADD'
and t.spec_cd= #{specCd}
and t.community_id= #{communityId}
and t.b_id= #{bId}
and t.fee_id= #{feeId}
and t.value= #{value}
update pay_fee_attrs t set t.status_cd = #{statusCd}
,t.b_id = #{newBId}
, t.value= #{value}
where 1=1
and t.attr_id= #{attrId}
and t.b_id= #{bId}
and t.spec_cd= #{specCd}
and t.community_id= #{communityId}
and t.fee_id= #{feeId}
insert into pay_fee_attrs (attr_id,status_cd,spec_cd,community_id,b_id,fee_id,value)
VALUES
(#{item.attrId},'0',#{item.specCd},#{item.communityId},'-1',#{item.feeId},#{item.value})