docker files fixes from liaqat
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("Accounts")]
|
||||
public class AccountDto : Document
|
||||
{
|
||||
public UserDto User { get; set; }
|
||||
public string Name { get; set; }
|
||||
public TradingExchanges Exchanges { get; set; }
|
||||
public AccountType Type { get; set; }
|
||||
public string Key { get; set; }
|
||||
public string Secret { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Backtests")]
|
||||
public class BacktestDto : Document
|
||||
{
|
||||
public decimal FinalPnl { get; set; }
|
||||
public int WinRate { get; set; }
|
||||
public decimal GrowthPercentage { get; set; }
|
||||
public decimal HodlPercentage { get; set; }
|
||||
public Ticker Ticker { get; set; }
|
||||
public string Scenario { get; set; }
|
||||
public List<PositionDto> Positions { get; set; }
|
||||
public List<SignalDto> Signals { get; set; }
|
||||
public Timeframe Timeframe { get; set; }
|
||||
public RiskLevel RiskLevel { get; set; }
|
||||
public string AccountName { get; set; }
|
||||
public List<CandleDto> Candles { get; set; }
|
||||
public BotType BotType { get; set; }
|
||||
public MoneyManagementDto MoneyManagement { get; internal set; }
|
||||
public MoneyManagementDto OptimizedMoneyManagement { get; internal set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
|
||||
[BsonCollection("BadTrader")]
|
||||
public class BadTraderDto : Document
|
||||
{
|
||||
public string Address { get; set; }
|
||||
public int Winrate { get; set; }
|
||||
public decimal Pnl { get; set; }
|
||||
public int TradeCount { get; set; }
|
||||
public decimal AverageWin { get; set; }
|
||||
public decimal AverageLoss { get; set; }
|
||||
public decimal Roi { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("BestTrader")]
|
||||
public class BestTraderDto : Document
|
||||
{
|
||||
public string Address { get; set; }
|
||||
public int Winrate { get; set; }
|
||||
public decimal Pnl { get; set; }
|
||||
public int TradeCount { get; set; }
|
||||
public decimal AverageWin { get; set; }
|
||||
public decimal AverageLoss { get; set; }
|
||||
public decimal Roi { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Candles")]
|
||||
public class CandleDto : Document
|
||||
{
|
||||
public TradingExchanges Exchange { get; set; }
|
||||
public Timeframe Timeframe { get; set; }
|
||||
public string Ticker { get; set; }
|
||||
[BsonDateTimeOptions]
|
||||
public DateTime OpenTime { get; set; }
|
||||
[BsonDateTimeOptions]
|
||||
public DateTime CloseTime { get; set; }
|
||||
public decimal Open { get; set; }
|
||||
public decimal Close { get; set; }
|
||||
public decimal High { get; set; }
|
||||
public decimal Low { get; set; }
|
||||
public decimal BaseVolume { get; set; }
|
||||
public decimal QuoteVolume { get; set; }
|
||||
public int TradeCount { get; set; }
|
||||
public decimal TakerBuyBaseVolume { get; set; }
|
||||
public decimal TakerBuyQuoteVolume { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("Fees")]
|
||||
public class FeeDto : Document
|
||||
{
|
||||
public decimal Cost { get; set; }
|
||||
public TradingExchanges Exchange { get; set; }
|
||||
public DateTime LastUpdate { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("MoneyManagement")]
|
||||
public class MoneyManagementDto : Document
|
||||
{
|
||||
public Timeframe Timeframe { get; set; }
|
||||
public RiskLevel RiskLevel { get; set; }
|
||||
public decimal BalanceAtRisk { get; set; }
|
||||
public decimal StopLoss { get; set; }
|
||||
public decimal TakeProfit { get; set; }
|
||||
public decimal Leverage { get; set; }
|
||||
public string Name { get; internal set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Positions")]
|
||||
public class PositionDto : Document
|
||||
{
|
||||
[BsonDateTimeOptions]
|
||||
public DateTime Date { get; set; }
|
||||
public TradeDto Open { get; set; }
|
||||
public TradeDto StopLoss { get; set; }
|
||||
public TradeDto TakeProfit1 { get; set; }
|
||||
public TradeDto TakeProfit2 { get; set; }
|
||||
public decimal ProfitAndLoss { get; set; }
|
||||
public TradeDirection OriginDirection { get; set; }
|
||||
public string Identifier { get; set; }
|
||||
public PositionStatus Status { get; set; }
|
||||
public Ticker Ticker { get; set; }
|
||||
public string SignalIdentifier { get; set; }
|
||||
public string AccountName { get; set; }
|
||||
public MoneyManagementDto MoneyManagement { get; set; }
|
||||
public PositionInitiator Initiator { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Scenarios")]
|
||||
public class ScenarioDto : Document
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public List<StrategyDto> Strategies { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Signals")]
|
||||
public class SignalDto : Document
|
||||
{
|
||||
public TradeDirection Direction { get; set; }
|
||||
public Confidence Confidence { get; set; }
|
||||
public DateTime Date { get; set; }
|
||||
public CandleDto Candle { get; set; }
|
||||
public string Identifier { get; set; }
|
||||
public Ticker Ticker { get; set; }
|
||||
public SignalStatus Status { get; set; }
|
||||
public Timeframe Timeframe { get; set; }
|
||||
public StrategyType Type { get; set; }
|
||||
public SignalType SignalType { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("SpotlighOverview")]
|
||||
public class SpotlighOverviewDto : Document
|
||||
{
|
||||
public List<SpotlightDto> Spotlights { get; set; }
|
||||
public DateTime DateTime { get; set; }
|
||||
public Guid Identifier { get; set; }
|
||||
public int ScenarioCount { get; set; }
|
||||
}
|
||||
|
||||
public class SpotlightDto
|
||||
{
|
||||
public ScenarioDto Scenario { get; set; }
|
||||
public List<TickerSignalDto> TickerSignals { get; set; }
|
||||
}
|
||||
|
||||
public class TickerSignalDto
|
||||
{
|
||||
public Ticker Ticker { get; set; }
|
||||
public List<SignalDto> FiveMinutes { get; set; }
|
||||
public List<SignalDto> FifteenMinutes { get; set; }
|
||||
public List<SignalDto> OneHour { get; set; }
|
||||
public List<SignalDto> FourHour { get; set; }
|
||||
public List<SignalDto> OneDay { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Strategies")]
|
||||
public class StrategyDto : Document
|
||||
{
|
||||
public StrategyType Type { get; set; }
|
||||
public Timeframe Timeframe { get; set; }
|
||||
public string Name { get; set; }
|
||||
public int? Period { get; set; }
|
||||
public int? FastPeriods { get; set; }
|
||||
public int? SlowPeriods { get; set; }
|
||||
public int? SignalPeriods { get; set; }
|
||||
public double? Multiplier { get; set; }
|
||||
public int? StochPeriods { get; set; }
|
||||
public int? SmoothPeriods { get; set; }
|
||||
public int? CyclePeriods { get; set; }
|
||||
public SignalType SignalType { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("TopVolumeTickers")]
|
||||
public class TopVolumeTickerDto : Document
|
||||
{
|
||||
public Ticker Ticker { get; set; }
|
||||
public DateTime Date { get; set; }
|
||||
public decimal Volume { get; set; }
|
||||
public int Rank { get; set; }
|
||||
public TradingExchanges Exchange { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,24 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections
|
||||
{
|
||||
[BsonCollection("Trades")]
|
||||
public class TradeDto : Document
|
||||
{
|
||||
[BsonDateTimeOptions]
|
||||
public DateTime Date { get; set; }
|
||||
public TradeDirection Direction { get; set; }
|
||||
public TradeStatus Status { get; set; }
|
||||
public TradeType TradeType { get; set; }
|
||||
public Ticker Ticker { get; set; }
|
||||
public decimal Fee { get; set; }
|
||||
public decimal Quantity { get; set; }
|
||||
public decimal Price { get; set; }
|
||||
public decimal Leverage { get; set; }
|
||||
public string ExchangeOrderId { get; set; }
|
||||
public string Message { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("Users")]
|
||||
public class UserDto : Document
|
||||
{
|
||||
public string Name { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("Workers")]
|
||||
public class WorkerDto : Document
|
||||
{
|
||||
public WorkerType WorkerType { get; set; }
|
||||
public DateTime StartTime { get; set; }
|
||||
public DateTime? LastRunTime { get; set; }
|
||||
public int ExecutionCount { get; set; }
|
||||
public TimeSpan Delay { get; set; }
|
||||
public bool IsActive { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using Managing.Domain.Workflows.Synthetics;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Attributes;
|
||||
using Managing.Infrastructure.Databases.MongoDb.Configurations;
|
||||
using static Managing.Common.Enums;
|
||||
|
||||
namespace Managing.Infrastructure.Databases.MongoDb.Collections;
|
||||
|
||||
[BsonCollection("Workflow")]
|
||||
public class WorkflowDto : Document
|
||||
{
|
||||
public string Name { get; set; }
|
||||
public string Description { get; set; }
|
||||
public WorkflowUsage Usage { get; set; }
|
||||
public List<SyntheticFlow> Flows { get; set; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user