Skip to content

PM-4970: Correct BA challenge fee split#1788

Merged
jmgasper merged 2 commits into
devfrom
PM-4970
May 1, 2026
Merged

PM-4970: Correct BA challenge fee split#1788
jmgasper merged 2 commits into
devfrom
PM-4970

Conversation

@jmgasper

@jmgasper jmgasper commented Apr 29, 2026

Copy link
Copy Markdown
Collaborator

What was broken
BA summary divided challenge line-item amounts by markup before displaying Member Payments, so a challenge with $50 in member payments and 33% markup showed $37.59 member payments and $12.40 fee instead of $50.00 and $16.50.

Root cause
Challenge billing-account rows already expose the member-payment subtotal for manager/admin challenge rows, but the modal treated every non-copilot row as a ledger total that still needed markup removed.

What was changed
Use the raw challenge line-item amount as manager/admin member payments and calculate the challenge fee from markup. Keep the existing reverse-markup behavior for engagement ledger rows and copilot fallback responses.

Any added/updated tests
Updated BillingAccountLineItemsModal coverage for the PM-4970 challenge split and added an assertion that engagement rows still reverse-calculate payment and fee amounts.


Open in Devin Review

What was broken
BA summary divided challenge line-item amounts by markup before displaying Member Payments, so a challenge with $50 in member payments and 33% markup showed $37.59 member payments and $12.40 fee instead of $50.00 and $16.50.

Root cause
Challenge billing-account rows already expose the member-payment subtotal for manager/admin challenge rows, but the modal treated every non-copilot row as a ledger total that still needed markup removed.

What was changed
Use the raw challenge line-item amount as manager/admin member payments and calculate the challenge fee from markup. Keep the existing reverse-markup behavior for engagement ledger rows and copilot fallback responses.

Any added/updated tests
Updated BillingAccountLineItemsModal coverage for the PM-4970 challenge split and added an assertion that engagement rows still reverse-calculate payment and fee amounts.
@jmgasper jmgasper requested a review from kkartunov as a code owner April 29, 2026 08:05
devin-ai-integration[bot]

This comment was marked as resolved.

@jmgasper jmgasper merged commit 73da2ea into dev May 1, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants