DD.WellWorkover.Cloud/AsbCloudApp/Repositories/INotificationRepository.cs

39 lines
1.3 KiB
C#
Raw Normal View History

using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;
using AsbCloudApp.Data;
using AsbCloudApp.Services;
namespace AsbCloudApp.Repositories;
/// <summary>
/// Репозиторий для уведомлений
/// </summary>
public interface INotificationRepository : ICrudRepository<NotificationDto>
{
/// <summary>
/// Метод для получения не отправленных уведомлений
/// </summary>
/// <param name="idUser"></param>
/// <param name="idNotificationTransport"></param>
/// <param name="cancellationToken"></param>
/// <returns></returns>
Task<IEnumerable<NotificationDto>> GetUnsentNotificationsAsync(int idUser,
int idNotificationTransport,
CancellationToken cancellationToken);
/// <summary>
/// Метод получения уведомлений по параметрам
/// </summary>
/// <param name="skip"></param>
/// <param name="take"></param>
/// <param name="idUser"></param>
/// <param name="idNotificationTransport"></param>
/// <param name="cancellationToken"></param>
/// <returns></returns>
Task<PaginationContainer<NotificationDto>> GetNotificationsAsync(int? skip,
int? take,
int idUser,
int idNotificationTransport,
CancellationToken cancellationToken);
}