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

39 lines
1.1 KiB
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-04 03:59:04 +03:00
[Key] public TimeSpan CreationDate { get; set; }
public TimeSpan UserId { get; set; }
2022-08-01 00:09:39 +03:00
2022-08-04 03:59:04 +03:00
public string Currency { get; }
public double Amount { get; } // To Buy
public double Quantity { get; } // Bought
public double Fee { get; }
public TimeSpan UploadedDate { get; }
public TimeSpan TransactionDate { get; }
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,
string currency, double amount, double quantity, double fee, TimeSpan uploadedDate, TimeSpan transactionDate)
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;
Amount = amount;
Quantity = quantity;
Fee = fee;
2022-08-01 00:09:39 +03:00
Currency = currency;
UploadedDate = uploadedDate;
TransactionDate = transactionDate;
2021-12-06 02:49:27 +03:00
}
}
}