using System; using AsbCloudApp.Data; using AsbCloudApp.Data.Trajectory; using ClosedXML.Excel; namespace AsbCloudInfrastructure.Services.Trajectory.Parser; public class TrajectoryFactManualParser : TrajectoryParser { protected override string SheetName => "Фактическая траектория"; protected override string TemplateFileName => "TrajectoryFactManualTemplate.xlsx"; public TrajectoryFactManualParser(IServiceProvider serviceProvider) : base(serviceProvider) { } protected override ValidationResultDto ParseRow(IXLRow row) { var trajectoryRow = new TrajectoryGeoFactDto { WellboreDepth = row.Cell(1).GetCellValue(), ZenithAngle = row.Cell(2).GetCellValue(), AzimuthGeo = row.Cell(3).GetCellValue(), AzimuthMagnetic = row.Cell(4).GetCellValue(), VerticalDepth = row.Cell(5).GetCellValue(), Comment = row.Cell(6).GetCellValue() }; //TODO: Добавить валидацию модели var validationResult = new ValidationResultDto { Item = trajectoryRow }; return validationResult; } }