refactor: replace DefaultLimitOffsetPage with LimitOffsetPage in multiple files and update timezone handling to use UTC

This commit is contained in:
Abhimanyu Saharan
2026-02-09 20:40:17 +05:30
parent 1f105c19ab
commit 020d02fa22
51 changed files with 302 additions and 192 deletions

View File

@@ -34,11 +34,13 @@ class BoardBase(SQLModel):
class BoardCreate(BoardBase):
"""Payload for creating a board."""
gateway_id: UUID
gateway_id: UUID | None = None
@model_validator(mode="after")
def validate_goal_fields(self) -> Self:
"""Require goal details when creating a confirmed goal board."""
"""Require gateway and goal details when creating a confirmed goal board."""
if self.gateway_id is None:
raise ValueError(_ERR_GATEWAY_REQUIRED)
if (
self.board_type == "goal"
and self.goal_confirmed