CodeLiturgy.Dashboard/BlueWest.Data.Capital/Transaction/FinanceOp.cs

33 lines
794 B
C#
Raw Normal View History

2021-12-06 02:49:27 +03:00
using System;
2022-08-20 05:47:32 +03:00
using System.Collections.Generic;
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
{
2022-08-18 22:59:13 +03:00
[MapFrom(typeof(FinanceOpCreate))]
public partial class FinanceOp
2021-12-06 02:49:27 +03:00
{
2022-08-19 19:47:35 +03:00
public int UserId { get; set; }
2022-08-13 06:35:36 +03:00
2022-08-20 05:47:32 +03:00
[Key] public int Id;
public TimeSpan CreationDate { get; set; }
[Required] public Currency Currency { get; }
2022-08-13 06:35:36 +03:00
2022-08-18 22:59:13 +03:00
public FinanceOpType Type {get;}
2022-08-13 03:53:22 +03:00
2022-08-13 06:35:36 +03:00
private string Description {get;}
2022-08-20 05:47:32 +03:00
2021-12-06 02:49:27 +03:00
2022-08-19 06:18:50 +03:00
public FinanceOp(TimeSpan creationDate, int userId,
2022-08-18 22:59:13 +03:00
Currency currency, FinanceOpType financeOpType)
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-18 22:59:13 +03:00
Type = financeOpType;
2021-12-06 02:49:27 +03:00
}
}
}