mirror of
https://github.com/nsnail/NetAdmin.git
synced 2025-12-29 00:55:48 +08:00
refactor: ♻️ 基础框架的实体更新逻辑 (#137)
Co-authored-by: tk <fiyne1a@dingtalk.com>
This commit is contained in:
@@ -70,6 +70,15 @@ public sealed class UserController(IUserCache cache, IConfigCache configCache)
|
||||
return Cache.DeleteAsync(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 编辑用户
|
||||
/// </summary>
|
||||
[Transaction]
|
||||
public Task<QueryUserRsp> EditAsync(EditUserReq req)
|
||||
{
|
||||
return Cache.EditAsync(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 用户是否存在
|
||||
/// </summary>
|
||||
@@ -165,7 +174,7 @@ public sealed class UserController(IUserCache cache, IConfigCache configCache)
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新用户头像
|
||||
/// 设置用户头像
|
||||
/// </summary>
|
||||
[Transaction]
|
||||
public Task<UserInfoRsp> SetAvatarAsync(SetAvatarReq req)
|
||||
@@ -209,15 +218,6 @@ public sealed class UserController(IUserCache cache, IConfigCache configCache)
|
||||
return Cache.SetPasswordAsync(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新用户
|
||||
/// </summary>
|
||||
[Transaction]
|
||||
public Task<QueryUserRsp> UpdateAsync(UpdateUserReq req)
|
||||
{
|
||||
return Cache.UpdateAsync(req);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 当前用户信息
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user