namespace MyOffice.Web.Models.Account { using Newtonsoft.Json; using System.ComponentModel.DataAnnotations; public class AccountViewModel { public string? Id { get; set; } [Required] public string Name { get; set; } = null!; public string Type { get; set; } = null!; [Required] public string CurrencyId { get; set; } = null!; public string? CurrencyName { get; set; } public bool AllowDelete { get; set; } public bool AllowManage { get; set; } public List? Categories { get; set; } [Required] public string CategoryId { get; set; } = null!; [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public List? AccessRights { get; set; } } public class AccountAccessViewModel { public class AccountAccessItemViewModel { public string UserId { get; set; } = null!; public bool AllowWrite { get; set; } } public string? Email { get; set; } public bool AllowWrite { get; set; } public List Accesses { get; set; } = null!; } }