Skip to main content

Design a store credit schema

Databases • Asked by gafemoyano

Hi, I was wondering if anyone has some experience building a store credit system into a market place style app. Eg: Users could purchase 100USD in adavance and receive 120USD in store credits as incentive. Then they could check out products with this credit.

So far I've been checkint out the solidus platform. They have two tables, one for the store_credit purchase which records the available amount, used amount and remaining amount. Then there's store_credit_events which records the individiaul transactions.
Then when it comes to payments, they handle it as another payment method which the user can select, however it starts getting very complicated as I'd need to develop a somewhat generic way to handle different payment methods.

I'm feeling a bit over my head with this and was wondering if anyone could point me in the right direction to get this feature off the ground.

Thank you,

Login or Create An Account to join the conversation.

Subscribe to the newsletter

Join 22,346+ developers who get early access to new screencasts, articles, guides, updates, and more.

    By clicking this button, you agree to the GoRails Terms of Service and Privacy Policy.

    More of a social being? We're also on Twitter and YouTube.