using GestionaDenuncias.Shared.Models;

namespace GestionaDenuncias.Shared.Services;

public interface IDenunciaStore
{
    Task EnsureSchemaAsync(CancellationToken cancellationToken = default);
    Task<List<DenunciasGestiona>> GetAllDenunciasAsync(CancellationToken cancellationToken = default);
    Task<List<DenunciasGestiona>> GetDenunciasByScopeAsync(DenunciaListScope scope, CancellationToken cancellationToken = default);
    Task<List<FicherosDenuncias>> GetAllFicherosAsync(CancellationToken cancellationToken = default);
    Task<List<FicherosDenuncias>> GetFicherosByDenunciaAsync(int denunciaId, CancellationToken cancellationToken = default);
    Task<List<GestionaUploadHistoryEntry>> GetGestionaUploadHistoryAsync(CancellationToken cancellationToken = default);
    Task<DenunciasGestiona?> GetDenunciaByIdAsync(int denunciaId, CancellationToken cancellationToken = default);
    Task UpsertDenunciaAsync(DenunciasGestiona denuncia, CancellationToken cancellationToken = default);
    Task UpsertFicherosAsync(IEnumerable<FicherosDenuncias> ficheros, CancellationToken cancellationToken = default);
    Task AddGestionaUploadHistoryAsync(
        GestionaUploadHistoryCreateRequest request,
        string username,
        CancellationToken cancellationToken = default);
    Task MarkFicherosAsUploadedAsync(
        int denunciaId,
        IEnumerable<string> fileNames,
        DateTime uploadedAtUtc,
        CancellationToken cancellationToken = default);
}
