Complete Ruby on Rails Ecommerce platform
Getting Started
Config
The Cart
Accounting
Addresses
Coupons
Deals
Fulfillment
Orders
Product Creation
Referrals
View the Project on GitHub drhenner/ror_ecommerce
This project is maintained by drhenner and many contributors.
Tables in Database
Lets say a customer pays their order with a credit card. First a new batch is created. The first transaction in this batch is Authorizing the credit card. The first transaction class is CreditCardPayment and the creation of the object would look like this:
CreditCardPayment.new_authorized_payment(user, total_cost)
This method will debit ACCOUNTS_RECEIVABLE and credit REVENUE.
Later when the item is marked as shipped the payment is captured from the creditcard. Then this method is executed:
CreditCardReceivePayment.new_capture_authorized_payment(user, total_cost)
This method will debit CASH and credit ACCOUNTS_RECEIVABLE.
The great news. All this just happens so you don't need to understand accounting. If you choose not to use the account data that is just fine. However if you eventually what to take your business to the next level you have all the data for the SEC or IRS.
The Transaction Ledgers table is simple the ledger table where the credits and debits are recorded. All transactions have two or more entries. The first entry logs credits and the other logs debits. In complex situations you could have more than 2 transactions but that is not the case for e-commerce.
Again, Luckily all this complexity is hidden from you and you can choose not to use this data when you get started.