has_accounts

Build Status

Rails plugin providing financal accounting models and helpers.

Install

In Rails simply add

gem 'has_accounts'

Integration

Generate and run migrations

rake has_accounts:install:migrations
rake db:migrate

Seed basic account data

AccountType.create!([
 

Add specific seed depending on the needs of your project, e.g.:

current_assets = AccountType.find_by_name('current_assets')
capital_assets = AccountType.find_by_name('capital_assets')
earnings = AccountType.find_by_name('earnings')
costs = AccountType.find_by_name('costs')

.create!([
 

Example

A few models are available:

class Booking
class 
class AccountType

There's also a ready to use module available to attach accountable functionality to existing models.

To use it, simply add the following to your Model:

include HasAccounts::Model

License

Released under the MIT license.