insert into
pay_control_rule(
name,
`condition`,
condition_id,
operator,
value,
action,
unit,
disable,
create_by,
create_date,
update_by,
update_date,
remarks,
del_flag,
site_id,
customer_id
)
values (
#{payControlRule.name,jdbcType=VARCHAR},
#{payControlRule.condition,jdbcType=VARCHAR},
#{payControlRule.conditionId,jdbcType=INTEGER},
#{payControlRule.operator,jdbcType=VARCHAR},
#{payControlRule.value,jdbcType=VARCHAR},
#{payControlRule.action,jdbcType=VARCHAR},
#{payControlRule.unit,jdbcType=VARCHAR},
#{payControlRule.disable,jdbcType=VARCHAR},
#{payControlRule.createBy,jdbcType=BIGINT},
#{payControlRule.createDate,jdbcType=TIMESTAMP},
#{payControlRule.updateBy,jdbcType=BIGINT},
#{payControlRule.updateDate,jdbcType=TIMESTAMP},
#{payControlRule.remarks,jdbcType=VARCHAR},
#{payControlRule.delFlag,jdbcType=VARCHAR},
#{payControlRule.siteId,jdbcType=BIGINT},
#{payControlRule.customerId,jdbcType=BIGINT}
)
update pay_control_rule set del_flag = 1 where id = #{id,jdbcType=INTEGER}
update pay_control_rule pcr
set
name = #{payControlRule.name},
pcr.condition = #{payControlRule.condition},
value = #{payControlRule.value},
operator = #{payControlRule.operator},
action = #{payControlRule.action},
unit = #{payControlRule.unit},
disable = {payControlRule.disable},
update_by = #{payControlRule.updateBy},
update_date = #{payControlRule.updateDate},
remarks = #{payControlRule.remarks},
del_flag = #{payControlRule.delFlag}
where id = #{payControlRule.id}