id, agent_id, agent_name, phone, user_pwd, with_pwd, nick_name, real_name, id_card,
account_type, user_amt, enable_amt, sum_charge_amt, sum_buy_amt, recom_phone, is_lock, is_login,
reg_time, reg_ip, reg_address, img1_key, img2_key, img3_key, is_active, auth_msg,
user_index_amt, enable_index_amt, user_fut_amt, enable_fut_amt, withdrawal_Pwd,trading_amount,djzj,vaild_number,leverage_ratio
delete from user
where id = #{id,jdbcType=INTEGER}
insert into user (id, agent_id, agent_name,
phone, user_pwd, with_pwd,
nick_name, real_name, id_card,
account_type, user_amt, enable_amt,
sum_charge_amt, sum_buy_amt, recom_phone,
is_lock,is_login, reg_time, reg_ip,
reg_address, img1_key, img2_key,
img3_key, is_active, auth_msg,
user_index_amt, enable_index_amt, user_fut_amt, enable_fut_amt, trading_amount,djzj
)
values (#{id,jdbcType=INTEGER}, #{agentId,jdbcType=INTEGER}, #{agentName,jdbcType=VARCHAR},
#{phone,jdbcType=VARCHAR}, #{userPwd,jdbcType=VARCHAR}, #{withPwd,jdbcType=VARCHAR},
#{nickName,jdbcType=VARCHAR}, #{realName,jdbcType=VARCHAR}, #{idCard,jdbcType=VARCHAR},
#{accountType,jdbcType=INTEGER}, #{userAmt,jdbcType=DECIMAL}, #{enableAmt,jdbcType=DECIMAL},
#{sumChargeAmt,jdbcType=DECIMAL}, #{sumBuyAmt,jdbcType=DECIMAL}, #{recomPhone,jdbcType=VARCHAR},
#{isLock,jdbcType=INTEGER},#{isLogin,jdbcType=INTEGER}, #{regTime,jdbcType=TIMESTAMP}, #{regIp,jdbcType=VARCHAR},
#{regAddress,jdbcType=VARCHAR}, #{img1Key,jdbcType=VARCHAR}, #{img2Key,jdbcType=VARCHAR},
#{img3Key,jdbcType=VARCHAR}, #{isActive,jdbcType=INTEGER}, #{authMsg,jdbcType=VARCHAR},
#{userIndexAmt,jdbcType=DECIMAL}, #{enableIndexAmt,jdbcType=DECIMAL},
#{userFutAmt,jdbcType=DECIMAL}, #{enableFutAmt,jdbcType=DECIMAL}, #{tradingAmount,jdbcType=DECIMAL},#{djzj,jdbcType=DECIMAL}
)
insert into user
id,
agent_id,
agent_name,
phone,
user_pwd,
with_pwd,
nick_name,
real_name,
id_card,
account_type,
user_amt,
enable_amt,
sum_charge_amt,
sum_buy_amt,
recom_phone,
is_lock,
is_login,
reg_time,
reg_ip,
reg_address,
img1_key,
img2_key,
img3_key,
is_active,
auth_msg,
user_index_amt,
enable_index_amt,
user_fut_amt,
enable_fut_amt,
trading_amount,
leverage_ratio,
#{id,jdbcType=INTEGER},
#{agentId,jdbcType=INTEGER},
#{agentName,jdbcType=VARCHAR},
#{phone,jdbcType=VARCHAR},
#{userPwd,jdbcType=VARCHAR},
#{withPwd,jdbcType=VARCHAR},
#{nickName,jdbcType=VARCHAR},
#{realName,jdbcType=VARCHAR},
#{idCard,jdbcType=VARCHAR},
#{accountType,jdbcType=INTEGER},
#{userAmt,jdbcType=DECIMAL},
#{enableAmt,jdbcType=DECIMAL},
#{sumChargeAmt,jdbcType=DECIMAL},
#{sumBuyAmt,jdbcType=DECIMAL},
#{recomPhone,jdbcType=VARCHAR},
#{isLock,jdbcType=INTEGER},
#{isLogin,jdbcType=INTEGER},
#{regTime,jdbcType=TIMESTAMP},
#{regIp,jdbcType=VARCHAR},
#{regAddress,jdbcType=VARCHAR},
#{img1Key,jdbcType=VARCHAR},
#{img2Key,jdbcType=VARCHAR},
#{img3Key,jdbcType=VARCHAR},
#{isActive,jdbcType=INTEGER},
#{authMsg,jdbcType=VARCHAR},
#{userIndexAmt,jdbcType=DECIMAL},
#{enableIndexAmt,jdbcType=DECIMAL},
#{userFutAmt,jdbcType=DECIMAL},
#{enableFutAmt,jdbcType=DECIMAL},
#{leverageRatio,jdbcType=VARCHAR},
update user
agent_id = #{agentId,jdbcType=INTEGER},
agent_name = #{agentName,jdbcType=VARCHAR},
phone = #{phone,jdbcType=VARCHAR},
user_pwd = #{userPwd,jdbcType=VARCHAR},
with_pwd = #{withPwd,jdbcType=VARCHAR},
nick_name = #{nickName,jdbcType=VARCHAR},
real_name = #{realName,jdbcType=VARCHAR},
id_card = #{idCard,jdbcType=VARCHAR},
account_type = #{accountType,jdbcType=INTEGER},
user_amt = #{userAmt,jdbcType=DECIMAL},
enable_amt = #{enableAmt,jdbcType=DECIMAL},
sum_charge_amt = #{sumChargeAmt,jdbcType=DECIMAL},
sum_buy_amt = #{sumBuyAmt,jdbcType=DECIMAL},
recom_phone = #{recomPhone,jdbcType=VARCHAR},
is_lock = #{isLock,jdbcType=INTEGER},
is_login = #{isLogin,jdbcType=INTEGER},
reg_time = #{regTime,jdbcType=TIMESTAMP},
reg_ip = #{regIp,jdbcType=VARCHAR},
reg_address = #{regAddress,jdbcType=VARCHAR},
img1_key = #{img1Key,jdbcType=VARCHAR},
img2_key = #{img2Key,jdbcType=VARCHAR},
img3_key = #{img3Key,jdbcType=VARCHAR},
is_active = #{isActive,jdbcType=INTEGER},
auth_msg = #{authMsg,jdbcType=VARCHAR},
user_index_amt = #{userIndexAmt,jdbcType=DECIMAL},
enable_index_amt = #{enableIndexAmt,jdbcType=DECIMAL},
user_fut_amt = #{userFutAmt,jdbcType=DECIMAL},
enable_fut_amt = #{enableFutAmt,jdbcType=DECIMAL},
trading_amount = #{tradingAmount,jdbcType=DECIMAL},
djzj = #{djzj,jdbcType=DECIMAL},
vaild_number =#{vaildNumber,jdbcType=VARCHAR}
leverage_ratio =#{leverageRatio,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
update user
set agent_id = #{agentId,jdbcType=INTEGER},
agent_name = #{agentName,jdbcType=VARCHAR},
phone = #{phone,jdbcType=VARCHAR},
user_pwd = #{userPwd,jdbcType=VARCHAR},
with_pwd = #{withPwd,jdbcType=VARCHAR},
nick_name = #{nickName,jdbcType=VARCHAR},
real_name = #{realName,jdbcType=VARCHAR},
id_card = #{idCard,jdbcType=VARCHAR},
account_type = #{accountType,jdbcType=INTEGER},
user_amt = #{userAmt,jdbcType=DECIMAL},
enable_amt = #{enableAmt,jdbcType=DECIMAL},
sum_charge_amt = #{sumChargeAmt,jdbcType=DECIMAL},
sum_buy_amt = #{sumBuyAmt,jdbcType=DECIMAL},
recom_phone = #{recomPhone,jdbcType=VARCHAR},
is_lock = #{isLock,jdbcType=INTEGER},
is_login = #{isLogin,jdbcType=INTEGER},
reg_time = #{regTime,jdbcType=TIMESTAMP},
reg_ip = #{regIp,jdbcType=VARCHAR},
reg_address = #{regAddress,jdbcType=VARCHAR},
img1_key = #{img1Key,jdbcType=VARCHAR},
img2_key = #{img2Key,jdbcType=VARCHAR},
img3_key = #{img3Key,jdbcType=VARCHAR},
is_active = #{isActive,jdbcType=INTEGER},
auth_msg = #{authMsg,jdbcType=VARCHAR},
user_index_amt = #{userIndexAmt,jdbcType=DECIMAL},
enable_index_amt = #{enableIndexAmt,jdbcType=DECIMAL},
user_fut_amt = #{userFutAmt,jdbcType=DECIMAL},
enable_fut_amt = #{enableFutAmt,jdbcType=DECIMAL},
trading_amount = #{tradingAmount,jdbcType=DECIMAL},
djzj = #{djzj,jdbcType=DECIMAL},
vaild_number =#{vaildNumber,jdbcType=VARCHAR}
where id = #{id,jdbcType=INTEGER}
update `user` set user_amt = user_amt + #{user_amt} where id = #{user_id}