"""Abstract repository interface for LeaveWish. Adds entity-specific queries on top of the generic CRUD contract. Concrete implementations live in app/repositories_impl//. """ from abc import abstractmethod from uuid import UUID from app.entities.leave_wish import LeaveWish from app.repositories.base import Repository class LeaveWishRepository(Repository[LeaveWish]): @abstractmethod async def get_by_workspace(self, workspace_id: UUID) -> list[LeaveWish]: """Return all leave wishes for a workspace.""" @abstractmethod async def get_by_series(self, series_id: UUID) -> list[LeaveWish]: """Return every occurrence row sharing `series_id`, oldest year first. A repeating wish is materialised into one row per year (see `app.entities.leave_wish`); this is how the service reaches the rest of a series from any one of them. """