2024-02-09 11:32:31 +05:00
|
|
|
using System;
|
2024-02-21 15:08:51 +05:00
|
|
|
using AsbCloudApp.Data.ProcessMaps;
|
2024-02-13 16:05:16 +05:00
|
|
|
using AsbCloudInfrastructure.Services.Parser;
|
2024-02-09 11:32:31 +05:00
|
|
|
|
|
|
|
namespace AsbCloudInfrastructure.Services.ProcessMapPlan.Parser;
|
|
|
|
|
2024-02-16 13:53:10 +05:00
|
|
|
public abstract class ProcessMapPlanParser<TDto> : ParserExcelService<TDto>
|
2024-02-09 11:32:31 +05:00
|
|
|
where TDto : ProcessMapPlanBaseDto
|
|
|
|
{
|
2024-02-13 16:05:16 +05:00
|
|
|
protected override int HeaderRowsCount => 2;
|
2024-02-09 11:32:31 +05:00
|
|
|
|
|
|
|
protected static int? GetIdMode(string? modeName) =>
|
|
|
|
modeName?.Trim().ToLower() switch
|
|
|
|
{
|
|
|
|
"ротор" => 1,
|
|
|
|
"слайд" => 2,
|
|
|
|
_ => null
|
|
|
|
};
|
|
|
|
}
|