Add admin endpoint to delete bundle backtest requests and implement related UI functionality + Add job resilient
This commit is contained in:
@@ -926,6 +926,20 @@ public class PostgreSqlBacktestRepository : IBacktestRepository
|
||||
}
|
||||
}
|
||||
|
||||
public async Task DeleteBundleBacktestRequestByIdAsync(Guid id)
|
||||
{
|
||||
var entity = await _context.BundleBacktestRequests
|
||||
.AsTracking()
|
||||
.FirstOrDefaultAsync(b => b.RequestId == id)
|
||||
.ConfigureAwait(false);
|
||||
|
||||
if (entity != null)
|
||||
{
|
||||
_context.BundleBacktestRequests.Remove(entity);
|
||||
await _context.SaveChangesAsync().ConfigureAwait(false);
|
||||
}
|
||||
}
|
||||
|
||||
public IEnumerable<BundleBacktestRequest> GetBundleBacktestRequestsByStatus(BundleBacktestRequestStatus status)
|
||||
{
|
||||
var entities = _context.BundleBacktestRequests
|
||||
|
||||
Reference in New Issue
Block a user