Files
myoffice/MyOffice.Data.Models/Accounts/Account.cs
T
2023-07-21 21:06:45 +03:00

36 lines
1.0 KiB
C#

namespace MyOffice.Data.Models.Accounts;
using Currencies;
public class Account
{
public Guid Id { get; set; }
public string CurrencyGlobalId { get; set; } = null!;
public CurrencyGlobal? CurrencyGlobal { get; set; }
public string Name { get; set; } = null!;
//public bool IsRest { get; set; }
public IEnumerable<AccountAccess>? AccessRights { get; set; }
public IEnumerable<Motion>? Motions { get; set; }
public IEnumerable<AccountAccountCategory>? Categories { get; set; }
}
public class AccountDetailed
{
public Account Account { get; set; } = null!;
public decimal TotalPlus { get; set; }
public decimal TotalMinus { get; set; }
public decimal Rest => TotalPlus - TotalMinus;
}
public struct AccountSimple
{
public Guid Id { get; set; }
public string Name { get; set; }
public string CurrencyId { get; set; }
public string CurrencyShortName { get; set; }
public decimal CurrencyRate { get; set; }
public decimal? TotalPlus { get; set; }
public decimal? TotalMinus { get; set; }
public decimal? Rest { get; set; }
}