Skip to content

feat: add time-based filtering and pagination to usage page#21

Open
carlosatta wants to merge 2 commits intodevelopfrom
feat/usage-time-filtering-pagination
Open

feat: add time-based filtering and pagination to usage page#21
carlosatta wants to merge 2 commits intodevelopfrom
feat/usage-time-filtering-pagination

Conversation

@carlosatta
Copy link
Copy Markdown
Contributor

Modifiche

  • Preset temporali recenti: aggiunta sezione "Recenti" nel DateRangePicker con 9 preset (1/3/5/10/15/30 min, 1/6/12 ore) che usano sliding window
  • Time picker per range custom: due input orario (HH:MM:SS) sotto il calendario con default 00:00:00-23:59:59, modificabili dall'utente
  • Paginazione server-side: parametri page/pageSize nel backend (default 50, max 200) con risposta pagination object
  • Parsing datetime condizionale: il backend preserva la precisione ISO datetime per stringhe con orario, normalizza solo per date pure
  • UI paginazione: controlli Precedente/Successiva con info pagina e totale record su UsagePage e ProjectLogsTab

File modificati

  • packages/service/src/routes/api.ts - backend pagination + datetime parsing
  • packages/dashboard/src/api.ts - tipi e parametri API
  • packages/dashboard/src/components/DateRangePicker.tsx - preset recenti + time picker
  • packages/dashboard/src/pages/UsagePage.tsx - paginazione + logica preset recenti
  • packages/dashboard/src/pages/project/ProjectLogsTab.tsx - stessa paginazione

- add recent time presets (1/3/5/10/15/30 min, 1/6/12 hours) to DateRangePicker
- add time picker inputs (HH:MM:SS) for custom date ranges with defaults 00:00:00–23:59:59
- implement server-side pagination with page/pageSize query params (default 50, max 200)
- update backend datetime parsing to preserve ISO datetime precision
- add pagination controls to UsagePage and ProjectLogsTab
- recent presets use sliding window recalculation on each fetch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant