DD.WellWorkover.Cloud/AsbCloudWebApi/Controllers/Trajectory/TrajectoryFactManualController.cs
Степанов Дмитрий 4874a9288b Рефакторинг контроллеров
1. Добавлен метод расширения для парсинга Excel файлов
2. Рефакторинг контроллеров траекторий
2024-01-29 15:39:39 +05:00

34 lines
1.2 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using AsbCloudApp.Data.Trajectory;
using AsbCloudApp.Repositories;
using AsbCloudApp.Requests.Import;
using AsbCloudApp.Services;
using AsbCloudInfrastructure.Services;
using AsbCloudInfrastructure.Services.Trajectory.Export;
using Microsoft.AspNetCore.Mvc;
namespace AsbCloudWebApi.Controllers.Trajectory;
/// <summary>
/// Фактическая траектория
/// </summary>
[ApiController]
[Route("api/well/{idWell}/[controller]")]
public class TrajectoryFactManualController : TrajectoryEditableController<TrajectoryGeoFactDto>
{
protected override string fileName => "ЕЦП_шаблон_файлаактическая_траектория.xlsx";
public TrajectoryFactManualController(IWellService wellService,
TrajectoryFactManualExportService trajectoryExportService,
ParserServiceFactory parserServiceFactory,
ITrajectoryEditableRepository<TrajectoryGeoFactDto> trajectoryRepository)
: base(wellService, parserServiceFactory, trajectoryExportService, trajectoryRepository)
{
}
protected override TrajectoryParserRequest ParserOptions => new()
{
IdParserService = ParserServiceFactory.IdTrajectoryFactManualParserService,
SheetName = "Фактическая траектория",
HeaderRowsCount = 2
};
}