feat: add Assign action to issue detail view #50
Reference in New Issue
Block a user
Delete Branch "%!s()"
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?
Description
The ROADMAP.md (Phase 2.2) specifies four action buttons for the Issue Detail view:
The "Apply Label" action exists. "Comment" and "Close" are tracked in #29. The "Assign" action is not yet tracked or implemented.
What to Do
1. Backend: Add assignee method to Gitea client
In
internal/gitea/client.go, add:This should call the Gitea API
PATCH /repos/{owner}/{repo}/issues/{index}with theassigneesfield.2. Backend: Add handler
In
internal/handlers/handlers.go, register and implement:The handler reads
assigneefrom the form, callsclient.AssignIssue, returns HTMX fragment on success.3. Backend: Fetch repo collaborators for the dropdown
In
internal/gitea/client.go, add:Used to populate the assignee selector.
4. Frontend: Add Assign form to issue_detail.html
In
internal/templates/issue_detail.html, within the Actions card:Acceptance Criteria
POST /issues/{owner}/{repo}/{index}/assigneesassigns the selected user and returns an HTMX fragmentgo test ./...passesRoadmap ref: Phase 2.2 — Issue Detail action buttons (Assign)
Depends on: leeworks-agents/gitea-mobile#29 (other action buttons in same template)
Triage Update (2026-03-26)
Priority: P2, medium
Status: Not started
Analysis:
AssignIssueandListCollaboratorsPOST /issues/{owner}/{repo}/{index}/assigneesissue_detail.htmland handlerIssueDetailto pass collaboratorsDelegation: @developer -- after #29 completes
Blocked by: #29
Manager Triage (2026-03-27)
Priority: P2 | Size: Medium | Assignee: AI-Engineer
Status: Blocked on #29 (Close Issue and Comment actions). Both issues modify
internal/templates/issue_detail.htmland should be sequenced to avoid merge conflicts.Action: Deferring until #29 is completed and merged. Will delegate to @developer at that time.
Management Update: PR #71 has been created with the Assign action implementation. The issue detail view now shows an assignee dropdown populated with repo collaborators, and assigning updates the issue on Gitea via HTMX inline response. Dependency on #29 is satisfied (merged).
Closed via PR #71 merge. Code reviewed and approved by repo manager.