feat: admin survey responses page with expandable detail and CSV export
- Backend: GET /admin/survey-responses (list with stats, invite join) - Backend: GET /admin/survey-responses/export (CSV download) - Frontend: SurveyResponsesPage with expandable row detail - Two-column Q&A grid with typed answer rendering (chips, ranked lists, quote blocks) - Stats cards (total responses, this week) - CSV export button with blob download - Sidebar nav + route wiring - Also: updated Q14 from product domain ranking to diagnostic prioritization Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -44,3 +44,20 @@ class SurveyInviteStatus(BaseModel):
|
||||
"""Public invite status check — minimal info."""
|
||||
name: str
|
||||
status: str
|
||||
|
||||
|
||||
class SurveyResponseDetail(BaseModel):
|
||||
"""Full survey response returned to admin."""
|
||||
id: str
|
||||
respondent_name: Optional[str]
|
||||
responses: dict[str, Any]
|
||||
source: str
|
||||
invite_name: Optional[str]
|
||||
created_at: datetime
|
||||
|
||||
|
||||
class SurveyResponseListResponse(BaseModel):
|
||||
"""List of survey responses with summary stats."""
|
||||
responses: list[SurveyResponseDetail]
|
||||
total: int
|
||||
this_week: int
|
||||
|
||||
Reference in New Issue
Block a user