forked from ddrilling/AsbCloudServer
Remove WellService.GetOperationsAsync() redundant method
This commit is contained in:
parent
b93ff717f2
commit
97df21c58b
@ -10,7 +10,6 @@ namespace AsbCloudApp.Services
|
||||
Task<IEnumerable<WellDto>> GetWellsByCompanyAsync(int idCompany, CancellationToken token);
|
||||
Task<IEnumerable<WellDto>> GetTransmittingWellsAsync(int idCompany, CancellationToken token);
|
||||
Task<bool> IsCompanyInvolvedInWellAsync(int idCompany, int idWell, CancellationToken token);
|
||||
Task<IEnumerable<WellOperationDto>> GetOperationsAsync(int idWell, CancellationToken token);
|
||||
Task<string> GetWellCaptionByIdAsync(int idWell, CancellationToken token);
|
||||
Task<IEnumerable<CompanyDto>> GetCompaniesAsync(int idWell, CancellationToken token);
|
||||
Task<WellDto> GetAsync(int idWell, CancellationToken token);
|
||||
|
@ -52,18 +52,6 @@ namespace AsbCloudInfrastructure.Services
|
||||
=> await cacheRelationCompaniesWells.ContainsAsync(r => r.IdWell == idWell &&
|
||||
r.IdCompany == idCompany, token).ConfigureAwait(false);
|
||||
|
||||
public async Task<IEnumerable<WellOperationDto>> GetOperationsAsync(int idWell, CancellationToken token)
|
||||
{
|
||||
var entities = await db.WellOperations.Where(o => o.IdWell == idWell)
|
||||
.AsNoTracking()
|
||||
.ToListAsync(token)
|
||||
.ConfigureAwait(false);
|
||||
|
||||
var dtos = entities.Adapt<WellOperationDto>();
|
||||
|
||||
return dtos;
|
||||
}
|
||||
|
||||
private static WellDto From(Well well)
|
||||
{
|
||||
var wellDto = new WellDto
|
||||
|
Loading…
Reference in New Issue
Block a user