DD.WellWorkover.Cloud/AsbCloudApp/Services/IDailyReportService.cs

56 lines
2.0 KiB
C#
Raw Normal View History

using AsbCloudApp.Data;
using AsbCloudApp.Data.DailyReport;
using System;
using System.Collections.Generic;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
namespace AsbCloudApp.Services
{
2022-08-05 17:16:11 +05:00
/// <summary>
/// Суточный рапорт (сводка)
/// </summary>
public interface IDailyReportService
2022-08-05 17:16:11 +05:00
{
2022-08-09 11:10:01 +05:00
/// <summary>
/// получить список сформированных рапортов по скважине за период времени
/// </summary>
/// <param name="idWell"></param>
2023-03-29 10:26:10 +05:00
/// <param name="begin"></param>
/// <param name="end"></param>
2022-08-09 11:10:01 +05:00
/// <param name="cancellationToken"></param>
/// <returns></returns>
Task<IEnumerable<DailyReportDto>> GetListAsync(int idWell, DateOnly? begin, DateOnly? end, CancellationToken cancellationToken);
2022-08-09 11:10:01 +05:00
/// <summary>
/// Добавить новый рапорт
/// </summary>
/// <param name="idWell"></param>
/// <param name="startDate"></param>
/// <param name="idUser"></param>
2022-08-09 11:10:01 +05:00
/// <param name="token"></param>
/// <returns></returns>
Task<int> AddAsync(int idWell, DateOnly startDate, int idUser, CancellationToken token);
2022-08-09 11:10:01 +05:00
/// <summary>
/// Сформировать файл рапорта
/// </summary>
/// <param name="idWell"></param>
/// <param name="date"></param>
/// <param name="token"></param>
/// <returns></returns>
Task<Stream?> MakeReportAsync(int idWell, DateOnly date, CancellationToken token);
/// <summary>
/// изменить блок данных для суточного рапорта
/// </summary>
/// <param name="idWell"></param>
/// <param name="startDate"></param>
/// <param name="dto"></param>
/// <param name="token"></param>
/// <returns></returns>
Task<int> UpdateBlockAsync(int idWell, DateOnly startDate, ItemInfoDto dto, CancellationToken token);
}
}