forked from ddrilling/AsbCloudServer
Смена типов для ProcessMapReportDataSaubStatDto
This commit is contained in:
parent
86674ba263
commit
72341e76d2
@ -44,7 +44,7 @@ public class ProcessMapReportDataSaubStatDto
|
||||
/// на начало интервала
|
||||
/// </para>
|
||||
/// </summary>
|
||||
public DateTime DateStart { get; set; }
|
||||
public DateTimeOffset DateStart { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Режим бурения (Ротор/слайд/ручной)
|
||||
|
@ -106,10 +106,11 @@ public class DailyReportService : IDailyReportService
|
||||
IdWell = well.Id
|
||||
};
|
||||
|
||||
var geDate = dailyReport.Date.ToDateTime(TimeOnly.MinValue, DateTimeKind.Unspecified);
|
||||
var ltDate = dailyReport.Date.AddDays(1).ToDateTime(TimeOnly.MinValue, DateTimeKind.Unspecified);
|
||||
|
||||
var factOperationRequest = new WellOperationRequest
|
||||
var offsetHours = wellService.GetTimezone(dailyReport.IdWell).Hours;
|
||||
var geDate = new DateTimeOffset(dailyReport.Date, TimeOnly.MinValue, TimeSpan.FromHours(offsetHours));
|
||||
var ltDate = new DateTimeOffset(dailyReport.Date.AddDays(1), TimeOnly.MinValue, TimeSpan.FromHours(offsetHours));
|
||||
|
||||
var factOperationRequest = new WellOperationRequest
|
||||
{
|
||||
IdWell = idWell,
|
||||
OperationType = WellOperation.IdOperationTypeFact,
|
||||
@ -369,8 +370,9 @@ public class DailyReportService : IDailyReportService
|
||||
|
||||
private async Task AddProcessMapWellDrillingBlockAsync(DailyReportDto dailyReport, CancellationToken cancellationToken)
|
||||
{
|
||||
var geDate = dailyReport.Date.ToDateTime(TimeOnly.MinValue, DateTimeKind.Unspecified);
|
||||
var leDate = dailyReport.Date.AddDays(1).ToDateTime(TimeOnly.MinValue, DateTimeKind.Unspecified);
|
||||
var offsetHours = wellService.GetTimezone(dailyReport.IdWell).Hours;
|
||||
var geDate = new DateTimeOffset(dailyReport.Date, TimeOnly.MinValue, TimeSpan.FromHours(offsetHours));
|
||||
var leDate = new DateTimeOffset(dailyReport.Date.AddDays(1), TimeOnly.MinValue, TimeSpan.FromHours(offsetHours));
|
||||
|
||||
var request = new DataSaubStatRequest();
|
||||
dailyReport.ProcessMapWellDrillingBlock = (await processMapReportDrillingService.GetAsync(dailyReport.IdWell, request,
|
||||
|
@ -174,7 +174,7 @@ public class ProcessMapReportDrillingService : IProcessMapReportDrillingService
|
||||
var result = new ProcessMapReportDataSaubStatDto()
|
||||
{
|
||||
IdWellSectionType = wellSectionType.Id,
|
||||
DateStart = firstElemInInterval.DateStart.DateTime,
|
||||
DateStart = firstElemInInterval.DateStart,
|
||||
WellSectionTypeName = wellSectionType.Caption,
|
||||
DepthStart = firstElemInInterval.DepthStart,
|
||||
DepthEnd = lastElemInInterval.DepthEnd,
|
||||
|
@ -113,7 +113,7 @@ public class DailyReportServiceTest
|
||||
private readonly ProcessMapReportDataSaubStatDto fakeProcessMapReportWellDrilling = new()
|
||||
{
|
||||
DrillingMode = "Ротор",
|
||||
DateStart = new DateTime(2023, 10, 26),
|
||||
DateStart = new DateTimeOffset(2023, 10, 26, 0, 0, 0, TimeSpan.Zero),
|
||||
DeltaDepth = 500,
|
||||
Rop = new PlanFactDto<double?>
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user