import { List } from '@iqser/common-ui/lib/utils';
import { DownloadFileType } from '../shared';

export interface IDownloadStatus {
    readonly creationDate?: string;
    readonly dossierId?: string;
    readonly downloadFileTypes?: List<DownloadFileType>;
    readonly fileIds?: List;
    readonly fileSize: number;
    readonly filename?: string;
    readonly lastDownload?: string;
    readonly mimeType?: string;
    readonly status?: DownloadStatusType;
    readonly storageId: string;
    readonly userId?: string;
}

export const DownloadStatuses = {
    FAILED: 'FAILED',
    GENERATING: 'GENERATING',
    QUEUED: 'QUEUED',
    READY: 'READY',
} as const;
export type DownloadStatusType = keyof typeof DownloadStatuses;
