Ror ecommerce

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.

ROR Ecommerce

Accounting

Tables in Database

Batch

A BATCH entry reflects the more physical aspects of accounting data entry. It is used to group together transactions entries into handy ‘chunks’, for example, a collection of cheques to be entered into the system... OR in this app's case all the transactions grouped for one order.

Transactions

Transactions are simply a place holder for one action within a batch. For example:

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.

Transaction Accounts

This is simply a reference table to what type of "account" is being credited or debited... (like ACCOUNTS RECEIVABLE or ACCOUNTS PAYABLE)

Transaction Ledgers

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.