CodeLiturgy.Dashboard/BlueWest.Data/Finance/FinanceTransaction.cs

36 lines
881 B
C#
Raw Normal View History

2021-12-06 02:49:27 +03:00
using System;
2022-08-04 03:59:04 +03:00
using System.ComponentModel.DataAnnotations;
2021-12-06 19:08:31 +03:00
using MapTo;
2021-12-06 02:49:27 +03:00
namespace BlueWest.Data
{
2021-12-10 03:04:48 +03:00
[MapFrom(typeof(FinanceTransactionInsertDto))]
2022-08-04 03:59:04 +03:00
public partial class FinanceTransaction
2021-12-06 02:49:27 +03:00
{
2022-08-13 03:53:22 +03:00
2022-08-04 03:59:04 +03:00
public TimeSpan UserId { get; set; }
2022-08-13 06:35:36 +03:00
[Key] public TimeSpan CreationDate { get; set; }
public Currency Currency { get; }
2022-08-13 05:59:37 +03:00
public FinanceTransactionType Type {get;}
2022-08-13 03:53:22 +03:00
2022-08-13 06:35:36 +03:00
private string Description {get;}
2022-08-13 03:53:22 +03:00
2021-12-06 02:49:27 +03:00
2022-08-04 03:59:04 +03:00
public FinanceTransaction()
{
}
2021-12-06 02:49:27 +03:00
2022-08-01 00:09:39 +03:00
public FinanceTransaction(TimeSpan creationDate, TimeSpan userId,
2022-08-13 06:35:36 +03:00
Currency currency, FinanceTransactionType financeTransactionType)
2021-12-06 02:49:27 +03:00
{
2022-08-01 00:09:39 +03:00
CreationDate = creationDate;
2021-12-06 02:49:27 +03:00
UserId = userId;
2022-08-01 00:09:39 +03:00
Currency = currency;
2022-08-13 06:35:36 +03:00
Type = financeTransactionType;
2021-12-06 02:49:27 +03:00
}
}
}