Merge pull request 'Фикс' (#98) from fix/process_map into dev

Reviewed-on: http://test.digitaldrilling.ru:8080/DDrilling/AsbCloudServer/pulls/98
This commit is contained in:
Никита Фролов 2023-08-17 16:13:41 +05:00
commit 23fd77eb9d
2 changed files with 3 additions and 6 deletions

View File

@ -87,10 +87,5 @@ namespace AsbCloudApp.Data.ProcessMap
/// Плановый процент использования spin master
/// </summary>
public double UsageSpin { get; set; }
/// <summary>
/// DTO типа секции
/// </summary>
public WellSectionTypeDto WellSectionType { get; set; } = null!;
}
}

View File

@ -75,6 +75,8 @@ public class ProcessMapPlanImportService : IProcessMapPlanImportService
public async Task<Stream> ExportAsync(int idWell, CancellationToken cancellationToken)
{
sections = (await wellSectionTypeRepository.GetAllAsync(cancellationToken)).ToArray();
var processMapPlans = (await processMapPlanRepository.GetByIdWellAsync(idWell,
cancellationToken)).ToArray();
@ -120,7 +122,7 @@ public class ProcessMapPlanImportService : IProcessMapPlanImportService
private void AddToRow(IXLRow row, ProcessMapPlanDto processMap)
{
row.Cell(columnWellSectionType).Value = processMap.WellSectionType.Caption;
row.Cell(columnWellSectionType).Value = sections.First(x => x.Id == processMap.IdWellSectionType).Caption;
row.Cell(columnMode).Value = GetModeCaption(processMap.IdMode);
row.Cell(columnDepthStart).Value = processMap.DepthStart;
row.Cell(columnDepthEnd).Value = processMap.DepthEnd;