insert into scenic_account(id, scenic_id, is_super, name, phone, account, password, create_time, update_time) values (#{id}, #{scenicId}, #{isSuper}, #{name}, #{phone}, #{account}, #{password}, now(), now()) insert into account_scenic(account_id, scenic_id, is_admin) values (#{accountId}, #{scenicId}, #{isAdmin}) update scenic_account name = #{name}, phone = #{phone}, account = #{account}, password = #{password}, update_time = now() where id = #{id} update scenic_account set status = (CASE WHEN status = 1 THEN 0 WHEN status = 0 THEN 1 ELSE null END) where id = #{id} delete from scenic_account where id = #{id} delete from scenic_account where scenic_id = #{scenicId} delete from account_scenic where scenic_id = #{scenicId} delete from account_scenic where account_id = #{accountId}