Ubisam-MobileGit/tasks/052-work-tab-cross-repository.md
choiminyeong f6ac20c8ed TASK-063: task records say what is actually open
No task waits on a Codex review; the redesign tasks are confirmed on the
product owner's Z Fold7; TASK-016's leftovers are on hold; no biometric
reauthentication.

Agent: main (opus)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 20:25:49 +09:00

67 lines
3.1 KiB
Markdown

# TASK-052: Work tab: issues and pull requests across repositories
Status: implemented; required checks pass; confirmed by the human product owner on their Z Fold7 (2026-09-29)
Owner: Claude
Reviewer: human product owner
## Outcome
Issues and pull requests could only be seen one repository at a time. The Work tab lists them
across every repository the account can see, narrowed by whose they are (everyone, review requested
of me, assigned to me, created by me), by state and by type.
## Scope
- Included: `GiteaWorkSearchApi` (`/repos/issues/search`), `WorkViewModel`, `WorkScreen`, opening one issue or
pull request directly (`Route.WorkItems` with a number, `WorkItemsViewModel.openItem`), which
notifications and the Home timeline now use as well.
- Excluded: text search, labels, milestones; any write.
## Writable paths
- `app/src/main/java/com/ubisam/ubgitea/feature/work/`
- `app/src/main/java/com/ubisam/ubgitea/data/workitems/GiteaWorkSearchApi.kt`
- `app/src/main/java/com/ubisam/ubgitea/domain/workitems/WorkSearchModels.kt`
- `app/src/main/java/com/ubisam/ubgitea/feature/workitems/WorkItemsViewModel.kt`
- `app/src/main/java/com/ubisam/ubgitea/ui/navigation/`
## Acceptance criteria
- [x] Each scope sends exactly one of Gitea's `review_requested` / `assigned` / `created` flags.
- [x] Changing scope, state or type reloads from the first page.
- [x] A result opens that issue or pull request; back returns to the list it came from.
- [x] The total is shown when the server reports one.
- [x] Loading, empty, offline, expired-session and server-error states are all shown.
- [x] Build, unit tests and lint pass.
- [ ] Confirmed on the human product owner's device (phone and unfolded Z Fold).
## Security and privacy
Read-only, within the scopes the app already requests.
## Required checks
```text
./gradlew compileDebugKotlin compileDebugUnitTestKotlin testDebugUnitTest assembleDebug lintDebug
```
## Evidence
Recorded on 2026-09-28 in the worktree `awesome-pascal-3f2ada`, with Android Studio's bundled JDK (`D:\AndroidStudio\jbr`, OpenJDK 21). TASK-050 to TASK-054 were built together and checked together:
- `./gradlew compileDebugKotlin compileDebugUnitTestKotlin testDebugUnitTest assembleDebug lintDebug` -- passed.
- Unit tests: 409 in 45 suites, 0 failures, 0 errors (289 before this work).
- Lint: 0 errors, 55 warnings (dependency updates, unused resources, KTX suggestions).
- Emulator (API 36, `sdk_gphone64_x86_64`): the debug APK installs and launches without a crash and shows the sign-in screen with the logo and the new palette. Nothing past sign-in could be reached: that needs a company account.
- Not done: any check on a physical device. None was visible to `adb` during this work.
- New tests: `GiteaWorkSearchApiTest` (14), `WorkViewModelTest` (8).
- Unit tests were written by a delegated worker from `handoff/2026-09-28_unit-tests-redesign.md`; the full run above was repeated here afterwards.
## Known limitations
- Gitea applies the scope flags together, so "assigned to me or created by me" cannot be one query; they are separate scopes.
## Review findings
None yet.