修复切换用户绑定服务器不生效的问题

This commit is contained in:
chuzhongzai 2024-04-06 19:34:50 +08:00
parent 61de3a8c2c
commit 246b1a2c26

View File

@ -14,8 +14,6 @@ public interface UserMapper {
@Select("select * from user where id = #{id}")
User selectUserById(int id);
@Select("select * from user where username = #{username}")
User selectUserByUsername(String username);
@Select("select * from user")
User[] selectAllUser();
@ -26,7 +24,8 @@ public interface UserMapper {
@Select("select id, storage_path, site_id from user where username=#{username} and passcode=#{passcode}")
User login(@Param("username") String username, @Param("passcode") String passcode);
@Update("update user set username=#{username}, passcode=#{passcode}, available_space=#{availableSpace}, total_space=#{totalSpace}, storage_path=#{storagePath} where id=#{id}")
@Update("update user set username=#{username}, passcode=#{passcode}, available_space=#{availableSpace}, " +
"total_space=#{totalSpace}, storage_path=#{storagePath}, site_id=#{siteId} where id=#{id}")
void updateUser(User user);
@Update("update user set available_space=#{availableSpace}, total_space=#{totalSpace} where id=#{id}")