feat(android): add-to-album overflow + timeline multi-select (Spec 064) #1280
Loading…
Reference in a new issue
No description provided.
Delete branch "spec/064-android"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Spec 064 Android-Lane (S4 + S5). Schließen nach PR #1278 (API-Batch-Endpoint, bereits gemergt).
MemoriesApi+HttpMemoriesApineuaddAlbumItems(...)→POST /api/albums/{id}/items/batch(BodymediaItemId-Liste, Antwort{added, skipped});AlbumDetailViewModel.addItemsvom POST-Loop auf einen Batch-Call umgestellt (danach einmaliges Re-Read für echte Thumbnails)ViewerActionsMenu(MoreVert + Dropdown) imViewerTopBar-trailing-Slot — Favorit, Teilen, Download, Info, Papierkorb + neu „Zu Album hinzufügen"; wiederverwendet dieViewerActionsRow-HandlerTimelineViewModelSelection-State (enterSelection/toggleSelection/exitSelection/trashSelected); Long-Press → Auswahl, Tap toggelt; Selection-Header (Zähler + Close) + Bottom-Toolbar: Zu bestehendem Album, Album erstellen, Löschen (mit Confirm), Auswahl aufhebenAddToAlbumViewModel+AddToAlbumSheetbedienen beide EinstiegspunkteVerification
./gradlew :app:testDebugUnitTest(workdirapps/android, erzwungener--rerundurch Orchestrator): 514 Tests, 0 Failures, 0 Errorsmain; die drei neuen Dateien ohne Findingsspec/064-android:Run scoped PR testssuccessRefs: spec 064, S064T003
Spec 064 S4+S5: bring the Android app to parity with the web's album-add flow and timeline multi-select. - API: add the new idempotent batch endpoint `POST /api/albums/{albumId}/items/batch` -> {added, skipped}. The singular `mediaItemId` field carrying an array is the server's contract, not a typo; documented as such. `AlbumDetailViewModel.addItems` now makes ONE batch call instead of looping a POST per photo, then re-reads album detail (the batch returns counts only) so the grid keeps real thumbnails. - Viewer: a "…"-overflow (MoreVert + DropdownMenu) in the ViewerTopBar trailing slot exposes favorite/share/download/info/trash plus the new "Zu Album hinzufügen". It reuses the existing ViewerActionsRow handlers rather than duplicating them. - Timeline multi-select (web parity): long-press enters selection, tap toggles, a selection header (count + close) and a bottom action bar offer add-to-existing-album, create-album, trash (with a TrashConfirmDialog) and clear-selection. After an action the selection clears and a snackbar fires; a partial trash failure keeps the failed ids selected so they stay retryable. - Shared AddToAlbumViewModel + AddToAlbumSheet (list accepted albums, add via batch, or create-and-add) back both the viewer overflow and the timeline bar; wired through the app-scoped ViewModel factory.