2026-05-14 11:00:12 -05:00
|
|
|
using Data.SeaHavenIndustries;
|
|
|
|
|
|
|
|
|
|
namespace SeaHaven.DataServices.Interfaces
|
|
|
|
|
{
|
|
|
|
|
public interface ITaskListTemplateDataService
|
|
|
|
|
{
|
|
|
|
|
Task<TaskListTemplate?> GetByIdAsync(int id);
|
|
|
|
|
Task<TaskListTemplate?> GetByIdWithItemsAsync(int id);
|
|
|
|
|
Task<IEnumerable<TaskListTemplate>> GetAllAsync();
|
|
|
|
|
Task<TaskListTemplate> AddAsync(TaskListTemplate template);
|
|
|
|
|
Task UpdateAsync(TaskListTemplate template);
|
|
|
|
|
Task DeleteAsync(int id);
|
|
|
|
|
Task<bool> ExistsAsync(int id);
|
2026-07-24 17:35:34 -03:00
|
|
|
|
|
|
|
|
// Cancelable query/command operations used by the TaskListTemplate service layer
|
|
|
|
|
Task<IEnumerable<TaskListTemplate>> GetActiveTemplatesWithItemsAsync(CancellationToken cancellationToken);
|
|
|
|
|
Task<TaskListTemplate?> GetTemplateWithItemsReadOnlyAsync(int id, CancellationToken cancellationToken);
|
|
|
|
|
Task<TaskListTemplate?> GetTemplateWithItemsForUpdateAsync(int id, CancellationToken cancellationToken);
|
|
|
|
|
Task<TaskListTemplate> AddTemplateAsync(TaskListTemplate template, CancellationToken cancellationToken);
|
|
|
|
|
Task ReplaceTemplateItemsAsync(TaskListTemplate template, IEnumerable<TaskListTemplateItem> newItems, CancellationToken cancellationToken);
|
|
|
|
|
Task<bool> DeactivateTemplateAsync(int id, CancellationToken cancellationToken);
|
2026-05-14 11:00:12 -05:00
|
|
|
}
|
|
|
|
|
}
|