Files
Artemy 2e9d7e625e Add primitive groups and required channel
Adds server-side group and channel management, private invitations, member moderation, avatar handling, and required-channel configuration. This change also introduces SignalR group profile/member notifications, updates registration to atomically join required channels, and adds EF migration and test coverage for group membership, permissions, and invitation expiry rules.
2026-10-04 10:35:07 +07:00

32 lines
981 B
C#

using System.ComponentModel.DataAnnotations;
namespace Govor.Contracts.Requests;
public class CreateGroupRequest
{
[Required, MaxLength(100)] public string Name { get; set; } = string.Empty;
[MaxLength(500)] public string Description { get; set; } = string.Empty;
public bool IsPrivate { get; set; } = true;
public bool IsChannel { get; set; }
}
public class UpdateGroupRequest
{
[Required, MaxLength(100)] public string Name { get; set; } = string.Empty;
[MaxLength(500)] public string Description { get; set; } = string.Empty;
public bool IsPrivate { get; set; }
}
public class CreateGroupInvitationRequest
{
[Range(1, 365)] public int ValidForDays { get; set; } = 7;
[Range(0, 1000000)] public int MaxParticipants { get; set; }
[MaxLength(500)] public string Description { get; set; } = string.Empty;
}
public class RequiredChannelRequest
{
public Guid? ChannelId { get; set; }
public bool AllowLeave { get; set; } = true;
}