8 Commits

Author SHA1 Message Date
defnotken
aec2a5023e remove created at for now 2025-09-25 10:25:12 -05:00
CakeAndBanana
69055b0f32 Change in groupfullinfo 2025-09-25 03:34:36 +02:00
CakeAndBanana
7abe2b1ef7 Changed GroupJoinDto 2025-09-25 02:03:41 +02:00
CakeAndBanana
848eb510ff Lightfinder merge into group changes 2025-09-24 15:04:02 +02:00
CakeAndBanana
75aebca693 Added client sendback of profileDTO 2025-09-17 05:37:04 +02:00
CakeAndBanana
96744f4f28 Adding getprofile in interface. 2025-09-17 02:41:42 +02:00
CakeAndBanana
43be25cc45 Added get of group profile, removed group from model. redone group data. 2025-09-17 02:38:21 +02:00
CakeAndBanana
28e1cc4695 Added changes for the API to support profiles 2025-09-17 02:09:23 +02:00
5 changed files with 13 additions and 3 deletions

View File

@@ -3,8 +3,8 @@
namespace LightlessSync.API.Data;
[MessagePackObject(keyAsPropertyName: true)]
public record GroupData(string GID, string? Alias = null)
public record GroupData(string GID, string? Alias = null, DateTime? CreatedAt = null)
{
[IgnoreMember]
public string AliasOrGID => string.IsNullOrWhiteSpace(Alias) ? GID : Alias;
public string AliasOrGID => Alias ?? GID;
}

View File

@@ -8,4 +8,4 @@ namespace LightlessSync.API.Dto.Group;
public record GroupPasswordDto(GroupData Group, string Password) : GroupDto(Group);
[MessagePackObject(keyAsPropertyName: true)]
public record GroupJoinDto(GroupData Group, string Password, GroupUserPreferredPermissions GroupUserPreferredPermissions) : GroupPasswordDto(Group, Password);
public record GroupJoinDto(GroupData Group, string Password, GroupUserPreferredPermissions GroupUserPreferredPermissions, bool Finder = false) : GroupPasswordDto(Group, Password);

View File

@@ -9,4 +9,5 @@ public record GroupPairDto(GroupData Group, UserData User) : GroupDto(Group)
public string UID => User.UID;
public string? UserAlias => User.Alias;
public string UserAliasOrUID => User.AliasOrUID;
}

View File

@@ -0,0 +1,6 @@
using LightlessSync.API.Data;
namespace LightlessSync.API.Dto.Group
{
public record GroupProfileDto(GroupData Group, string? Description, string? Tags, string? PictureBase64) : GroupDto(Group);
}

View File

@@ -21,6 +21,7 @@ public interface ILightlessHub
Task Client_GroupPairJoined(GroupPairFullInfoDto groupPairInfoDto);
Task Client_GroupPairLeft(GroupPairDto groupPairDto);
Task Client_GroupSendFullInfo(GroupFullInfoDto groupInfo);
Task Client_GroupSendProfile (GroupProfileDto groupInfo);
Task Client_GroupSendInfo(GroupInfoDto groupInfo);
Task Client_ReceiveServerMessage(MessageSeverity messageSeverity, string message);
Task Client_UpdateSystemInfo(SystemInfoDto systemInfo);
@@ -58,6 +59,8 @@ public interface ILightlessHub
Task<GroupJoinInfoDto> GroupJoinHashed(GroupJoinHashedDto dto);
Task GroupLeave(GroupDto group);
Task GroupRemoveUser(GroupPairDto groupPair);
Task<GroupProfileDto> GroupGetProfile(GroupDto dto);
Task GroupSetProfile(GroupProfileDto dto);
Task GroupSetUserInfo(GroupPairUserInfoDto groupPair);
Task<List<GroupFullInfoDto>> GroupsGetAll();
Task GroupUnbanUser(GroupPairDto groupPair);