diff --git a/AsbCloudApp/Services/IWellOperationService.cs b/AsbCloudApp/Services/IWellOperationService.cs
index a9105939..5dac4c9b 100644
--- a/AsbCloudApp/Services/IWellOperationService.cs
+++ b/AsbCloudApp/Services/IWellOperationService.cs
@@ -6,6 +6,7 @@ using System.Threading.Tasks;
namespace AsbCloudApp.Services
{
+#nullable enable
///
/// сервис операций по скважине
///
@@ -36,8 +37,8 @@ namespace AsbCloudApp.Services
Task> GetOperationsAsync(
int idWell,
int? operationType = null,
- IEnumerable sectionTypeIds = null,
- IEnumerable operationCategoryIds = null,
+ IEnumerable? sectionTypeIds = null,
+ IEnumerable? operationCategoryIds = null,
DateTime begin = default,
DateTime end = default,
double minDepth = double.MinValue,
@@ -62,8 +63,8 @@ namespace AsbCloudApp.Services
Task> GetGroupOperationsStatAsync(
int idWell,
int? operationType = null,
- IEnumerable sectionTypeIds = null,
- IEnumerable operationCategoryIds = null,
+ IEnumerable? sectionTypeIds = null,
+ IEnumerable? operationCategoryIds = null,
DateTime begin = default,
DateTime end = default,
double minDepth = double.MinValue,
@@ -76,7 +77,7 @@ namespace AsbCloudApp.Services
///
///
///
- Task GetAsync(int id, CancellationToken token);
+ Task GetAsync(int id, CancellationToken token);
//todo: idWell Не нужен
///
@@ -122,4 +123,5 @@ namespace AsbCloudApp.Services
///
DateTimeOffset? FirstOperationDate(int idWell);
}
+#nullable disable
}
diff --git a/AsbCloudInfrastructure/Services/WellOperationService/WellOperationService.cs b/AsbCloudInfrastructure/Services/WellOperationService/WellOperationService.cs
index 8cb9b606..24b9eccb 100644
--- a/AsbCloudInfrastructure/Services/WellOperationService/WellOperationService.cs
+++ b/AsbCloudInfrastructure/Services/WellOperationService/WellOperationService.cs
@@ -77,8 +77,8 @@ namespace AsbCloudInfrastructure.Services.WellOperationService
public async Task> GetOperationsAsync(
int idWell,
int? operationType = default,
- IEnumerable sectionTypeIds = default,
- IEnumerable operationCategoryIds = default,
+ IEnumerable? sectionTypeIds = null,
+ IEnumerable? operationCategoryIds = null,
DateTime begin = default,
DateTime end = default,
double minDepth = double.MinValue,
@@ -139,7 +139,7 @@ namespace AsbCloudInfrastructure.Services.WellOperationService
return result;
}
- public async Task?> GetGroupOperationsStatAsync(
+ public async Task> GetGroupOperationsStatAsync(
int idWell,
int? operationType = default,
IEnumerable? sectionTypeIds = default,
@@ -159,9 +159,7 @@ namespace AsbCloudInfrastructure.Services.WellOperationService
end,
minDepth,
maxDepth,
- token);
- if (query is null)
- return null;
+ token);
var entities = await query
.Select(o => new {
o.IdCategory,
@@ -210,7 +208,7 @@ namespace AsbCloudInfrastructure.Services.WellOperationService
return dtos;
}
- public async Task GetAsync(int id,
+ public async Task GetAsync(int id,
CancellationToken token = default)
{
@@ -274,8 +272,8 @@ namespace AsbCloudInfrastructure.Services.WellOperationService
private IQueryable BuildQuery(
int idWell,
int? operationType = default,
- IEnumerable sectionTypeIds = default,
- IEnumerable operationCategoryIds = default,
+ IEnumerable? sectionTypeIds = null,
+ IEnumerable? operationCategoryIds = null,
DateTime begin = default,
DateTime end = default,
double minDepth = double.MinValue,