import { ProjectStatus } from "@/helpers/validators" export const priorityType=['baja','media','alta'] as const export type PriorityType= typeof priorityType[number] export const taskStatus=['no iniciada','en proceso','completada','revisada','cancelada','reabierta'] as const export type TaskStatus = typeof taskStatus[number] | 'pendiente' | 'expirada' export const projectStatus=['no iniciada','en proceso','completada','cancelada','reabierta'] as const export type projectStatus = typeof projectStatus[number] export interface Task { id: string; startDate: string; expireDate?: string; startedTime?: Date; endedTime?: Date; status?: TaskStatus; createdAt?: Date; comments: string; priority: PriorityType; updatedAt?: Date; floorName:string, projectId:string, areaId:string projectName:string, areaName:string userId:string user?:User } export interface WeeklyActivity { day: string; count: number; } export interface MonthlyActivity { compleatedTasks: number; floors: number; projects: number; } export interface TaskId{ value:string } export interface FilterTasks { searchQuery?: string; status?: TaskStatus; statusFilter?: 'pendientes' | 'expiradas' | 'completada'; range?:string onlyRecentModifiedTask?:boolean onlyUserTask?:boolean limit?:number } // Interface para Project export interface Project { id: number; name: string; } // Interface para Area export interface Area { id: number; type: string; } // Interface para Floor export interface Floor { id: number; name: string; } // Interface para User export interface User { id: string; firstName: string; lastName: string; } // Interface para la estructura de la consulta de Task export interface ProjectTaskQueryResult{ id:string, name:string, status:ProjectStatus task:Task[] } export interface TasksByDate{ startDate:string, tasks:Task[] }