Tinker
Resources
Agent logs
Agent memories
Agent sessions
Agent terminal logs
Agents
Comments
Epics
Projects
Proposals
Tickets
Avo user
Resources
Agent logs
Agent memories
Agent sessions
Agent terminal logs
Agents
Comments
Epics
Projects
Proposals
Tickets
Avo user
Home
Epics
Fix tickets#show comment UI: implement comment creation for humans
Edit
Fix tickets#show comment UI: implement comment creation for humans
Cancel
Save
Title
*
Project
*
Choose an option
alpha
tinker
Create new project
Description
The tickets#show view has UI for adding comments but it's not implemented - currently throwing a 500 error. Need to implement the comment creation functionality for human users. ## Current State **File**: Tickets show view (likely `/rails/app/views/tickets/show.html.haml` or similar in Avo/dashboard) **Problem:** - Comment form UI exists but backend is missing/broken - Submitting comment causes 500 error - Humans cannot add comments via web interface **Note**: Comments work via MCP (`add_comment` tool), but web UI is broken. ## Requirements ### 1. Fix the 500 Error - Identify the broken code path - Fix the controller/action handling comment submission - Ensure form posts to correct endpoint ### 2. Implement Comment Creation - Add controller action to handle form submission - Create comment linked to current ticket - Set comment author to current human user (not agent) - Redirect back to ticket show page ### 3. Comment Form UI - Textarea for comment content - Comment type selector (note, question, decision) - Submit button - Display existing comments with author, timestamp, type ### 4. Human vs Agent Comments - Human comments: created via web UI, author = human user - Agent comments: created via MCP tool, author = agent ## Implementation **Controller action:** ```ruby # In TicketsController or similar def create_comment @ticket = Ticket.find(params[:id]) @ticket.comments.create!( content: params[:comment][:content], comment_type: params[:comment][:comment_type] || 'note', agent_id: current_user.id, # or user_id depending on auth created_by: 'human' ) redirect_to ticket_path(@ticket), notice: "Comment added" end ``` **Route:** ```ruby resources :tickets do post 'add_comment', to: 'tickets#create_comment', as: :add_comment end ``` **Form:** ```haml = form_with url: add_comment_ticket_path(@ticket), local: true do |f| = f.text_area :content, rows: 3, placeholder: "Add a comment..." = f.select :comment_type, ['note', 'question', 'decision'], selected: 'note' = f.submit "Add Comment" ``` ## Acceptance Criteria - [ ] Tickets show page loads without 500 error - [ ] Comment form displays and submits successfully - [ ] Comments are created with correct ticket_id - [ ] Comments show author (human), timestamp, and type - [ ] Comments created via web UI distinguishable from agent comments - [ ] Form validation works (content required) - [ ] Redirect back to ticket show page after submission
Avo
· © 2026 AvoHQ ·
v3.27.0
Close modal
Are you sure?
Yes, I'm sure
No, cancel