1.7 KiB
1.7 KiB
title, status, type, priority, created_at, updated_at
| title | status | type | priority | created_at | updated_at |
|---|---|---|---|---|---|
| UX: Allow editing caught pokemon details on run page | draft | feature | normal | 2026-03-21T22:00:55Z | 2026-03-21T22:04:08Z |
Problem
Users can mistype catch level, nickname, or other details when recording an encounter, but there's no way to correct mistakes from the run page. The only option is to go through admin — which doesn't even support editing encounters for a specific run.
Current State
- Backend
EncounterUpdateschema (backend/src/app/schemas/encounter.py:18-23): Supportsnickname,status,faint_level,death_cause,current_pokemon_id— but NOTcatch_level - Frontend
UpdateEncounterInput(frontend/src/types/game.ts:169-175): Same fields as backend, missingcatch_level - Run page encounter modal: Clicking a route with an existing encounter opens the modal in "edit" mode, but only allows changing pokemon/nickname/status — no catch_level editing
- The encounter modal is the create/edit modal — editing is done by re-opening it on an existing encounter
Approach
Backend
- Add
catch_level: int | None = NonetoEncounterUpdateschema - Verify the PATCH
/encounters/{id}endpoint appliescatch_levelupdates (checkencounters.pyupdate handler)
Frontend
- Add
catchLevel?: numbertoUpdateEncounterInputtype - Ensure the encounter modal shows catch_level as editable when editing an existing encounter
- Add catch_level field to the encounter edit modal (shown when editing existing encounters)
Testing
- Test updating catch_level via API
- Test that the frontend sends catch_level in update requests
- Verify existing create/update flows still work