A valid CTB member whose self+upline program-73 entries are both empty was
keeping their raw CTB username as the ClickBaitPays ref (a nonexistent CBP
account would eat the signups — Marty caught it live with ?ref=r0705243024).
Now: endpoint code no_entry (or its reason string) -> ref=cryptoteambuild,
hub aligned to the member, fix-it nudge shown. Unknown values still pass
through verbatim for genuine legacy CBP usernames.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Endpoint walks one hop up ref_by when the member's own program-73 entry is
empty; response carries source: self|sponsor. Calculator shows an adapted
nudge on upline fallback (alignment held, but claim your own referrals).
Hub invite still aligns to the SHARER either way.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Last remaining Telegram destination on the page — now a hub-link that
personalizes to the sponsor's CTB Rewards invite like every other CTA.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
?ref=<ctb-username> now forward-resolves to the member's real ClickBaitPays
ref (Marty hit this live with ref=r03430451480 -> now resolves opgnetwerk);
?ctb=<cbp-username> reverse-resolves symmetrically. Wrong-slot links from
confused members self-heal instead of leaking CTB usernames into CBP refs.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Visitors now funnel to the CTB Rewards hub (ctbrewards.saasy.top/invite/
<ctb-username>) instead of the Telegram sponsor group - every group link
and the generated plan's handshake steps now point at the sponsor's hub
invite, which keeps referrals aligned in Crypto Team Build.
Identity layer: one member, two usernames. Share links may carry
?ctb=<ctb-username> (canonical) or legacy ?ref=<cbp-username>; the new
member-program-link.php endpoint on cryptoteambuild.com (downline-builder
program #73) resolves either direction. ?ctb= looks up the sponsor's own
ClickBaitPays ref for the signup buttons; ?ref= reverse-resolves the CTB
username so the hub invite personalizes. Endpoint down or entry missing ->
graceful fallback to cryptoteambuild + a visible sponsor nudge explaining
how to fix it (add your CBP username to the downline-builder entry).
Share URLs now carry both identities; Sponsor Guide documents the hub +
the downline-builder tip. Engine untouched: test_scenarios ALL PASS.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- boostSim(): generic lane simulator to 3xL7, exact same reserve rules as computePlan (verified: agrees on all 8 baseline starts)
- enumerateBoostCombos(): every affordable add-on for the free slots, activation once per level
- Overview card ranks every combo vs 'just bank it' by time to endgame; share link carries &boost=
- test_scenarios section 8: baseline consistency, combo costs, ranking, the +$300 scenario (best: add L3+L2, 3 cycles faster than banking)
- The second toggle block (lines 1718-1725) was overriding the checkbox state
- When numPeople > 0, it was showing sponsor columns regardless of checkbox
- Now uses so both conditions must be met
- Referral columns stay hidden by default even when simulating a referral plan
- Added setTimeout(updateAll, 100) so the referral columns are hidden from the very first page render, not just after user interaction
- Without this, the <td> cells with .referral-col class were visible even though the checkbox was unchecked
- Added .referral-col class to overview body <td>s (10% and cumulative columns)
- Added .referral-col class to timeline body <td>s (commission and cumulative)
- Added .referral-col class to 'Sponsor's Cumulative' header in both overview and timeline tables
- All sponsor columns now hide/show together via the checkbox toggle
Phase table now has 7 columns:
- Their Gross Payout / Their Net Profit / Sponsor's 10% / Sponsor's Cumulative
- Timeline tab: 'Sponsor's Commission/Month' and 'Sponsor's Cumulative'
- Table-wrap overflow-x: auto for mobile scrollability
When options change (gift level, self-fund level), the share link box and QR codes update correctly, but the plan text still showed the old bare referral link. Now the plan text uses the same getShareUrl() call that generates the custom share link, so the referral link in the plan text stays in sync with the selected options.
Bug: The 'Cumulative to You' column showed /usr/bin/bash.00 (no gift) or a frozen
value (with gift) instead of the actual running total of referral earnings.
Fix:
- Separate ROI tracking (cumulative until gift cost is recouped) from
cumulative payout display (always accumulates across all phases)
- Use roiCum/roiRow for ROI tracking, cumRunning for display
- 3× L7 Endgame uses 1 cycle (not 0) so its contribution is counted
- Highlight phase where ROI is achieved (not the phase after it)
L1 Only: 5.48, L2+L1: 3.04, L3+L1: 47.68, L4+L3: 39.28,
L5+L4: 05.84, L6: ,527.92, L7: ,795.92, 3×L7: ,767.92