rubyforgood / rubyforgood/awbw

Transferred-in reg still appears under the roster "unpaid" payment filter

Open Beginner friendly
#2,160 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
15
Forks
26
Avg merge
12h 42m
Merged PRs (30d)
242

Description

Follow-up from #1944 / PR #2044.

A transferred-in registration's balance lives on its source registration, so it owes nothing to the new event. Reporting totals already exclude it (dashboard billable basis + EventRevenueFigures), but the roster payment-status filter does not: EventRegistration.not_paid_in_full (raw SQL summing allocations vs events.cost_cents) still matches a transferred-in reg (0 allocations, cost > 0), so it shows up under payment_status: "unpaid".

Suggested fix
  • Exclude transferred-in regs from not_paid_in_full (and treat them consistently in paid_in_full / the payment_status scope), e.g. AND transferred_from_registration_id IS NULL, mirroring not_transferred_in.
  • Confirm the roster "Paid/Unpaid" counts and the payment_status filter agree with the dashboard's billable basis.
Context
  • app/models/event_registration.rbpaid_in_full / not_paid_in_full / payment_status scopes; not_transferred_in scope already exists.
  • Deliberately scoped out of #1944 (a filter, not a reporting total).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in app/models/event_registration.rb by reading the paid_in_full, not_paid_in_full, payment_status, and existing not_transferred_in scopes. Compare their behavior with the dashboard billable basis and EventRevenueFigures, then check the roster Paid/Unpaid counts and payment_status filter. Done means transferred-in registrations are excluded consistently and the roster agrees with the dashboard totals.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby, sql
Domain
backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.