add mare profiles

This commit is contained in:
rootdarkarchon
2023-03-19 19:00:22 +01:00
parent f6a471f457
commit 2b829af4f8
22 changed files with 625 additions and 57 deletions

View File

@@ -162,6 +162,13 @@ public partial class ApiController
return Task.CompletedTask;
}
public Task Client_UserUpdateProfile(UserDto dto)
{
Logger.LogDebug("Client_UserUpdateProfile: {dto}", dto);
ExecuteSafely(() => Mediator.Publish(new ClearProfileDataMessage(dto.User)));
return Task.CompletedTask;
}
public Task Client_UserUpdateSelfPairPermissions(UserPermissionsDto dto)
{
Logger.LogDebug("Client_UserUpdateSelfPairPermissions: {dto}", dto);
@@ -277,6 +284,12 @@ public partial class ApiController
_mareHub!.On(nameof(Client_UserUpdateOtherPairPermissions), act);
}
public void OnUserUpdateProfile(Action<UserDto> act)
{
if (_initialized) return;
_mareHub!.On(nameof(Client_UserUpdateProfile), act);
}
public void OnUserUpdateSelfPairPermissions(Action<UserPermissionsDto> act)
{
if (_initialized) return;