Add per-form results aggregator page - #2315
Merged
Merged
Conversation
maebeale
force-pushed
the
maebeale/form-results-aggregator
branch
from
August 22, 2026 12:35
7eef0b2 to
2b85ccf
Compare
maebeale
marked this pull request as ready for review
August 22, 2026 12:36
Forms had a submissions list but no way to see the answers rolled up. The new /forms/:id/results page aggregates every submission question by question — selects/checkboxes as charts with count+percentage legends, free-text as newest-first answer lists, files as counts — reusing the roster breakdown card so it reads as one reporting family. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The results grid was a fixed 2-column layout, so a short card next to a tall chart left dead space. Switch to CSS multi-column (masonry) so cards pack tightly and fill the width. Add a dev seed form exercising every field type with ~30 varied submissions so the page has rich data. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Even when a question has 25 or fewer responses, keep a direct path to the full filterable submissions list. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ndex - Reuse a shared "View all N responses" footer across select, text, and file result cards (via an optional footer slot on _breakdown_card). - Show it even when a question has 25 or fewer answers. - Form submissions index Event column now reads "<event name> · Month Year". Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- State fields (mailing_state/organization_state/ce_license_issuing_state) chart as a US choropleth, country fields as a world map — same controllers as the registrant breakdowns, matched off field_identifier so free-text answers still map. - Add "View all N responses" to the written-in answers sub-card. - Showcase seed gains state + country fields so the maps have data. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
maebeale
force-pushed
the
maebeale/form-results-aggregator
branch
from
August 22, 2026 15:44
2b85ccf to
4734be4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 suggested review level: 3 Read 📖 new read-only reporting page + one PORO; main risk is answer-value tallying
What is the goal of this PR and why is this important?
Forms have a submissions list but no rolled-up view of the answers.
/forms/:id/results) that aggregates every submission, question by question, in form order.events/_breakdown_cardso it reads as one reporting family.How did you approach the change?
Aggregation (
FormResponseAggregatorPORO)[label, count]tallies. Sector/age-group ids resolved to names; multi-select split on", ".Other: <text>write-ins tally under the base option and surface as a separate written-in list.Page
Navigation
form_resultsreturn-to branches so the submissions index/show eyebrows return to Results.Dev data
db/seeds/dev/form_results_showcase.rb(taskdb:seed:form_results_showcase, part ofdb:seed:dev): one standalone form exercising every field type + ~30 varied submissions, so the page has rich data to eyeball.Anything else to add?
FormResponseAggregatorservice spec, request specs for the new action, andpage_bg_classalignment.🤖 Generated with Claude Code