Fix genetic backend
This commit is contained in:
@@ -80,8 +80,7 @@ namespace Managing.Application.Backtesting
|
||||
bool withCandles = false,
|
||||
string requestId = null)
|
||||
{
|
||||
var account = await GetAccountFromConfig(config);
|
||||
var candles = GetCandles(account, config.Ticker, config.Timeframe, startDate, endDate);
|
||||
var candles = GetCandles(config.Ticker, config.Timeframe, startDate, endDate);
|
||||
|
||||
var result = await RunBacktestWithCandles(config, candles, user, withCandles, requestId);
|
||||
|
||||
@@ -165,7 +164,7 @@ namespace Managing.Application.Backtesting
|
||||
};
|
||||
}
|
||||
|
||||
private List<Candle> GetCandles(Account account, Ticker ticker, Timeframe timeframe,
|
||||
private List<Candle> GetCandles(Ticker ticker, Timeframe timeframe,
|
||||
DateTime startDate, DateTime endDate)
|
||||
{
|
||||
var candles = _exchangeService.GetCandlesInflux(TradingExchanges.Evm, ticker,
|
||||
@@ -400,6 +399,12 @@ namespace Managing.Application.Backtesting
|
||||
return backtests;
|
||||
}
|
||||
|
||||
public IEnumerable<Backtest> GetBacktestsByRequestId(string requestId)
|
||||
{
|
||||
var backtests = _backtestRepository.GetBacktestsByRequestId(requestId).ToList();
|
||||
return backtests;
|
||||
}
|
||||
|
||||
public Backtest GetBacktestByIdForUser(User user, string id)
|
||||
{
|
||||
var backtest = _backtestRepository.GetBacktestByIdForUser(user, id);
|
||||
@@ -462,7 +467,5 @@ namespace Managing.Application.Backtesting
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user