Guest cap $5 -> $2: GUEST_BUDGET default, emails, docs, tests
This commit is contained in:
1 parent
0f12c63f5e
commit
6be8e2d632
6 files changed
+45
-45
No files matched your search
@@ -2,7 +2,7 @@
|
||||
"""Member self-serve guest requests — structurally isolated from live services.
|
||||
|
||||
WHY THIS EXISTS
|
||||
The member path creates REAL guest accounts ($5 of credits, Cloudron users,
|
||||
The member path creates REAL guest accounts ($2 of credits, Cloudron users,
|
||||
invitation email) once approved, and the trial gate decides when. Every path
|
||||
proven here runs against a FIXTURE database with the network layer REPLACED
|
||||
BY A RAISING GUARD: any code path that tries to reach Cloudron, LiteLLM, OC,
|
||||
@@ -25,7 +25,7 @@ WHY THIS EXISTS
|
||||
members invite guests.
|
||||
APPROVAL (the panel action)
|
||||
9. Approve fires the FULL guest pipeline: row marked account_type='guest',
|
||||
$5 credit, ledger row inviter → recipient, the invitation email (the
|
||||
$2 credit, ledger row inviter → recipient, the invitation email (the
|
||||
INVITING member named in it), newsletter subscribe — and the request
|
||||
row becomes 'approved'.
|
||||
10. Approving a request whose guard now refuses (state moved) records the
|
||||
@@ -306,7 +306,7 @@ def main():
|
||||
"SELECT account_type, balance, credit_balance FROM members WHERE email = ?",
|
||||
("friend@x.org",)).fetchone()
|
||||
check("approve: recipient row marked guest", acct and acct[0] == "guest", str(acct))
|
||||
check("approve: $5 non-expiring credit", acct and acct[2] == 5.0, str(acct))
|
||||
check("approve: $2 non-expiring credit", acct and acct[2] == 2.0, str(acct))
|
||||
ledger = conn.execute(
|
||||
"SELECT inviter_email, recipient_email, status FROM guests WHERE recipient_email = 'friend@x.org'"
|
||||
).fetchall()
|
||||
|
||||
Reference in new issue
Block a user