c65f2b5385
- Add src/application/dtos/cursor.rs with three shared types:
· PageCursor trait — default base64url+JSON encode/decode; one bare
impl line per cursor struct
· CursorQuery struct — standard limit/cursor/sort_by query params with
limit_clamped() and decode_cursor<C>() helpers; compose via flatten
· CursorListResponse<T> — standard {items, next_cursor?} envelope with
from_oversized() and with_cursor() builders
- Migrate GrantCursor to impl PageCursor (remove duplicate encode/decode)
- Update GET /api/grants/incoming/resources:
· SharedWithMeQuery now embeds CursorQuery via #[serde(flatten)]
· Replace file/folder nullable pair with ResourceContentDto (untagged
enum) under a single always-present 'resource' field
· SharedWithMeDto is now a type alias for CursorListResponse<SharedWithMeItemDto>
· Handler uses q.paging.limit_clamped() and decode_cursor<GrantCursor>()
- Add docs/architecture/resource-listing.md — authoritative contract for
all listing endpoints (cursor design, SQL keyset WHERE, sort_by naming,
Rust + JS skeletons, compliance table, migration guide)
- Register doc in VitePress sidebar and architecture index
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
23 lines
510 B
Rust
23 lines
510 B
Rust
pub mod address_book_dto;
|
|
pub mod cursor;
|
|
pub use cursor::{CursorListResponse, CursorQuery, PageCursor};
|
|
pub mod app_password_dto;
|
|
pub mod calendar_dto;
|
|
pub mod contact_dto;
|
|
pub mod device_auth_dto;
|
|
pub mod display_helpers;
|
|
pub mod favorites_dto;
|
|
pub mod file_dto;
|
|
pub mod folder_dto;
|
|
pub mod folder_listing_dto;
|
|
pub mod grant_dto;
|
|
pub mod i18n_dto;
|
|
pub mod pagination;
|
|
pub mod playlist_dto;
|
|
pub mod recent_dto;
|
|
pub mod search_dto;
|
|
pub mod settings_dto;
|
|
pub mod share_dto;
|
|
pub mod trash_dto;
|
|
pub mod user_dto;
|