Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Mogwai's avatar

Prepaid Credit Account

Is there a way with Spark to realize a credit account? This allows customers to book individual packages?

0 likes
4 replies
fwartner's avatar

Thinking of "credit" like credits at DO?

In case you´re using stripe for billing, you be able to give the user kinda like a "credit" to his balance.. So the user will ONLY charged, if the credits are at null.

I´m working on an application that allows you to manage your stripe-data easier because i think that stipe´s dashboard is a little bit overwhelming ^^

Mogwai's avatar

@fwartner

Mir gehts um ein Guthaben basiertes Prepaidsystem wo der Uder dann je nach Gusto verschiedene Pakete und/oder Items buchen kann. Und das halt völlig unabhängig von bestimmten voreingestellten Summen sondern am besten mit einem Textfeld wo er selber ne Zahl einträgt und der Betrag dann halt auf sein internes Konto aufgeladen wird.

fwartner's avatar

Eine Lösung wäre:

Neue Tabelle (inkl. Model) für die Credits erstellen und über einen EventHandler die Credits runterzählen. Dazu kommt dann natürlich noch der Gegenpart für die Pakete/Items..

Du ziehst einfach den Preis von den "Extras" von den Credits ab.

Dann kannst du über ein Pivot dem Nutzer die jeweiligen "Extras" hinzufügen..

Ich hoffe, dass das hilft und auch das ist, was du suchst..

Please or to participate in this conversation.