forked from ddrilling/AsbCloudServer
This commit is contained in:
commit
aceefe637a
@ -25,12 +25,8 @@ namespace AsbCloudApp.Comparators
|
|||||||
/// <param name="y"></param>
|
/// <param name="y"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public int Compare(IId? x, IId? y)
|
public int Compare(IId? x, IId? y)
|
||||||
{
|
=> (x?.Id??0).CompareTo(y?.Id??0);
|
||||||
if (x is null || y is null)
|
|
||||||
return 0;
|
|
||||||
else
|
|
||||||
return x.Id.CompareTo(y.Id);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
///
|
///
|
||||||
@ -40,10 +36,10 @@ namespace AsbCloudApp.Comparators
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public bool Equals(IId? x, IId? y)
|
public bool Equals(IId? x, IId? y)
|
||||||
{
|
{
|
||||||
if (x is null || y is null)
|
if (x is not null && y is not null)
|
||||||
return false;
|
|
||||||
else
|
|
||||||
return x.Id == y.Id;
|
return x.Id == y.Id;
|
||||||
|
|
||||||
|
return x == y;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -9,12 +9,10 @@ namespace AsbCloudApp.Comparators
|
|||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public bool Equals(TelemetryUserDto? prevUser, TelemetryUserDto? nextUser)
|
public bool Equals(TelemetryUserDto? prevUser, TelemetryUserDto? nextUser)
|
||||||
{
|
{
|
||||||
if (prevUser is null || nextUser is null)
|
if (prevUser is not null && nextUser is not null)
|
||||||
return false;
|
return prevUser.Id == nextUser.Id;
|
||||||
else if (prevUser.Id == nextUser.Id)
|
|
||||||
return true;
|
return prevUser == nextUser;
|
||||||
else
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Название
|
/// Название
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Caption { get; set; } = string.Empty;
|
public string Caption { get; set; } = null!;
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public double? Latitude { get; set; }
|
public double? Latitude { get; set; }
|
||||||
|
@ -28,7 +28,7 @@ namespace AsbCloudApp.Data
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// пользователь панели оператора
|
/// пользователь панели оператора
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string User { get; set; } = null!;
|
public string? User { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// текст сообщения
|
/// текст сообщения
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// название текущей операции генерации
|
/// название текущей операции генерации
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string Operation { get; set; } = string.Empty;
|
public string? Operation { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// номер текущей страницы
|
/// номер текущей страницы
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
namespace AsbCloudApp.Data
|
namespace AsbCloudApp.Data
|
||||||
{
|
{
|
||||||
#nullable enable
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// DTO формирования рапорта
|
/// DTO формирования рапорта
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
namespace AsbCloudApp.Data
|
namespace AsbCloudApp.Data
|
||||||
{
|
{
|
||||||
#nullable enable
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// DTO журнала запросов
|
/// DTO журнала запросов
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -63,5 +62,4 @@ namespace AsbCloudApp.Data
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string? ExceptionStack { get; set; } = null!;
|
public string? ExceptionStack { get; set; } = null!;
|
||||||
}
|
}
|
||||||
#nullable disable
|
|
||||||
}
|
}
|
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
namespace AsbCloudApp.Data
|
namespace AsbCloudApp.Data
|
||||||
{
|
{
|
||||||
#nullable enable
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// DTO статистики запросов по пользователю
|
/// DTO статистики запросов по пользователю
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -48,5 +47,4 @@ namespace AsbCloudApp.Data
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public UserDto User { get; set; } = null!;
|
public UserDto User { get; set; } = null!;
|
||||||
}
|
}
|
||||||
#nullable disable
|
|
||||||
}
|
}
|
||||||
|
@ -41,6 +41,6 @@ namespace AsbCloudApp.Data
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Бурильщик
|
/// Бурильщик
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public DrillerDto Driller { get; set; } = null!;
|
public DrillerDto? Driller { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
namespace AsbCloudApp.Data
|
namespace AsbCloudApp.Data
|
||||||
{
|
{
|
||||||
#nullable enable
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// âðåìåííàÿ çîíà
|
/// âðåìåííàÿ çîíà
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -45,7 +45,7 @@ namespace AsbCloudApp.Data
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// статистика за всю скважину
|
/// статистика за всю скважину
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public PlanFactBase<StatOperationsDto>? Total { get; set; }
|
public PlanFactBase<StatOperationsDto> Total { get; set; } = new();
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// компании участвующие в строительстве скважины
|
/// компании участвующие в строительстве скважины
|
||||||
|
@ -34,6 +34,6 @@ namespace AsbCloudApp.Data
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// DTO скважины
|
/// DTO скважины
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public WellInfoDto Well { get; set; } = null!;
|
public WellInfoDto? Well { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -118,11 +118,11 @@ namespace AsbCloudApp.Data
|
|||||||
public static bool operator >(TimeDto a, TimeDto b) => a.TotalSeconds > b.TotalSeconds;
|
public static bool operator >(TimeDto a, TimeDto b) => a.TotalSeconds > b.TotalSeconds;
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public int CompareTo(TimeDto other)
|
public int CompareTo(TimeDto? other)
|
||||||
=> TotalSeconds - other.TotalSeconds;
|
=> TotalSeconds - other?.TotalSeconds??0;
|
||||||
|
|
||||||
/// <inheritdoc/>
|
/// <inheritdoc/>
|
||||||
public override bool Equals(object obj)
|
public override bool Equals(object? obj)
|
||||||
{
|
{
|
||||||
if (ReferenceEquals(this, obj))
|
if (ReferenceEquals(this, obj))
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user