2023-11-03 19:24:58 +05:00
|
|
|
using System;
|
|
|
|
using System.Threading;
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
using AsbCloudApp.Data;
|
|
|
|
using AsbCloudApp.Data.DailyReport;
|
|
|
|
using AsbCloudApp.Requests;
|
|
|
|
|
|
|
|
namespace AsbCloudApp.Services.DailyReport;
|
|
|
|
|
2023-11-14 11:01:34 +05:00
|
|
|
/// <summary>
|
|
|
|
/// Суточные отчёты
|
|
|
|
/// </summary>
|
2023-11-03 19:24:58 +05:00
|
|
|
public interface IDailyReportService
|
|
|
|
{
|
|
|
|
/// <summary>
|
2023-11-14 11:01:34 +05:00
|
|
|
/// Обновить или создать суточный отчёт
|
2023-11-03 19:24:58 +05:00
|
|
|
/// </summary>
|
2023-11-14 11:01:34 +05:00
|
|
|
/// <param name="dateDailyReport"></param>
|
2023-11-03 19:24:58 +05:00
|
|
|
/// <param name="idUser"></param>
|
|
|
|
/// <param name="editableBlock"></param>
|
|
|
|
/// <param name="cancellationToken"></param>
|
2023-11-14 11:01:34 +05:00
|
|
|
/// <param name="idWell"></param>
|
2023-11-03 19:24:58 +05:00
|
|
|
/// <returns></returns>
|
2023-11-14 11:01:34 +05:00
|
|
|
Task<int> UpdateOrInsertAsync<TBlock>(int idWell, DateTime dateDailyReport, int idUser, TBlock editableBlock,
|
|
|
|
CancellationToken cancellationToken)
|
|
|
|
where TBlock : ItemInfoDto;
|
2023-11-03 19:24:58 +05:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Получить сформированный суточный отчёт
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="idWell"></param>
|
2023-11-14 11:01:34 +05:00
|
|
|
/// <param name="dateDailyReport"></param>
|
2023-11-03 19:24:58 +05:00
|
|
|
/// <param name="cancellationToken"></param>
|
|
|
|
/// <returns></returns>
|
2023-11-14 11:01:34 +05:00
|
|
|
Task<DailyReportDto> GetAsync(int idWell, DateTime dateDailyReport, CancellationToken cancellationToken);
|
2023-11-03 19:24:58 +05:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Получить список суточных отчётов по скважине
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="idWell"></param>
|
|
|
|
/// <param name="request"></param>
|
|
|
|
/// <param name="cancellationToken"></param>
|
|
|
|
/// <returns></returns>
|
2023-11-14 11:01:34 +05:00
|
|
|
Task<PaginationContainer<DailyReportDto>> GetAsync(int idWell, FileReportRequest request, CancellationToken cancellationToken);
|
2023-11-03 19:24:58 +05:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Получить диапазон дат по которым возможно сформировать суточный отчёты
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="idWell"></param>
|
|
|
|
/// <param name="cancellationToken"></param>
|
|
|
|
/// <returns></returns>
|
|
|
|
Task<DatesRangeDto?> GetDatesRangeAsync(int idWell, CancellationToken cancellationToken);
|
|
|
|
}
|