Remove program status from org-wide UI#1993
Open
maebeale wants to merge 1 commit into
Open
Conversation
maebeale
commented
Jul 15, 2026
| # already-loaded affiliations so a profile can classify many events without an | ||
| # N+1. No facilitator affiliation starting before the date => :new; an earlier | ||
| # one still active on the date => :ongoing; all earlier ones ended => :reinstated. | ||
| def facilitator_status_as_of(date) |
Collaborator
Author
There was a problem hiding this comment.
🤖 From Claude: Deliberately computed in-memory (over the already-loaded affiliations) rather than reusing the DB-backed Organization#facilitator_status_on, so classifying a paginated page of ~9 events doesn't fire 2 queries per event. Same classification rule, just no N+1.
maebeale
commented
Jul 15, 2026
| title: event.title, | ||
| data: { turbo_frame: "_top" }, | ||
| class: "inline-flex items-center rounded-full text-xs font-medium border px-2.5 py-0.5 #{OrganizationDecorator.program_status_classes(status)}" do %> | ||
| <%= status.to_s.titleize %> · <%= event.abbreviation.presence || event.title.truncate(24) %> |
Collaborator
Author
There was a problem hiding this comment.
🤖 From Claude: Falls back to a truncated title when abbreviation is blank so existing events still render a sensible chip. Chips are gated behind manage? to keep program status admin-only, matching how it was treated on the old index column.
06ca55a to
7fb2709
Compare
New/Reinstate/Ongoing can only be determined relative to a specific event, so showing it as a global org attribute was misleading. Per-event program status is surfaced on the org profile in a separate PR (event abbreviations, #1995). - Drop the admin-only "Program" column from the org index. - Drop the now-orphaned Organization.program_statuses_by_id bulk classifier. - Drop the "Program status" block from the org edit form's Affiliations section. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
7fb2709 to
c1bb63c
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 📖 removes a misleading admin column/field + one orphaned model method; no data changes
What is the goal of this PR and why is this important?
How did you approach the change?
Organization.program_statuses_by_idbulk classifier (only the index used it).organization_status(Active/Inactive/…) search filter untouched — it's a real persisted field, not the program status.program_status/program_status_badgeare unchanged and still used in event context (event dashboard, onboarding, scholarships).Anything else to add?