using IWS5.Core.Enums;

namespace IWS5.Core.DTO;

public class ProcessPermissionsDTO(
    int ProcessId,
    Guid GroupId,
    IReadOnlyCollection<ATRightAllowRight> AllowedProcessPermissions,
    IReadOnlyCollection<ProcessFieldPermissionsDTO> AllowedFolderFieldPermissions,
    IReadOnlyCollection<DocumentTemplateListItemDTO> Templates,
    IReadOnlyCollection<ProcessFieldPermissionsDTO> AllowedDocumentFieldPermissions)
{
    public int ProcessId { get; private set; } = ProcessId;
    public Guid GroupId { get; private set; } = GroupId;
    public IReadOnlyCollection<ATRightAllowRight> AllowedProcessPermissions { get; private set; } = AllowedProcessPermissions;
    public IReadOnlyCollection<ProcessFieldPermissionsDTO> AllowedFolderFieldPermissions { get; private set; } = AllowedFolderFieldPermissions;
    public IReadOnlyCollection<DocumentTemplateListItemDTO> Templates { get; private set; } = Templates;
    public IReadOnlyCollection<ProcessFieldPermissionsDTO> AllowedDocumentFieldPermissions { get; private set; } = AllowedDocumentFieldPermissions;
}

public class DocumentTemplateListItemDTO(
    Guid templateId,
    string templateName,
    bool inLimit)
{
    public Guid TemplateId { get; private set; } = templateId;
    public string TemplateName { get; private set; } = templateName;
    public bool InLimit { get; private set; } = inLimit;
}