Skip to main content

Double entry book keeping in Django

Project description

Double entry book keeping in Django.

The initial priority is to ensure the model layer works reliably. Ultimately the intention is to integrate this with swiftwind to provide an accounting & billing system for a communal household. This interface should be intuitive and suitable for non-experts.

https://img.shields.io/pypi/v/django-hordak.svg https://img.shields.io/pypi/dm/django-hordak.svg https://img.shields.io/github/license/waldocollective/django-hordak.svg https://travis-ci.org/waldocollective/django-hordak.svg?branch=master https://coveralls.io/repos/github/waldocollective/django-hordak/badge.svg?branch=master

Installation

Installation using pip:

pip install django-hordak  # Release coming soon

Tested against:

  • Django >= 1.8, <= 1.10

  • Python 2.7, 3.4, 3.5, nightly

  • Postgres 9

Hordak may work with Postgres 8, but this is not tested for.

It may also be possible to run Hordak on a non-Postgres RDBMS if one skips the *_check_* migrations, as these are Postgres-specific. However, this is not recommended as it could lead to database inconsistency.

Design

The core models consist of:

  • Account - Such as ‘Accounts Receivable’, a bank account, etc. Accounts can be arranged as a tree structure, where the balance of the parent account is the summation of the balances of all its children.

  • Transaction - Represents a movement between accounts. Each transaction must have two or more legs.

  • Leg - Represents a flow of money into (debit) or out of (credit) a transaction. Debits are represented by negative amounts, and credits by positive amounts. The sum of all a transaction’s legs must equal zero. This is enforced with a database constraint.

Additionally, there are models which related to the import of external bank statement data:

  • StatementImport - Represents a simple import of zero or more statement lines relating to a specific Account.

  • StatementLine - Represents a statement line. StatementLine.create_transaction() may be called to create a transaction for the statement line.

Loading Fixtures

Fixture data can be loaded as normal:

./manage.py loaddata top-level-accounts

Creating Fixtures

Create fixtures as follows:

./manage.py dumpdata hordak --indent=2 --natural-primary --natural-foreign > fixtures/my-fixture.json

Usage

TBA

django-hordak is packaged using seed.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-hordak-1.0.0.tar.gz (16.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_hordak-1.0.0-py3-none-any.whl (21.9 kB view details)

Uploaded Python 3

File details

Details for the file django-hordak-1.0.0.tar.gz.

File metadata

  • Download URL: django-hordak-1.0.0.tar.gz
  • Upload date:
  • Size: 16.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for django-hordak-1.0.0.tar.gz
Algorithm Hash digest
SHA256 d9aed5aba3c8c3e49d7fb64b2643ae1425863fdd1ab39cd92ed6a3fddc6ec639
MD5 00592a7df62e030a8bd29c57e8f4b84e
BLAKE2b-256 89db996df54c0f0b4a1bbf22bc859bc138f559da4cee0c20d18f1bd748416708

See more details on using hashes here.

File details

Details for the file django_hordak-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for django_hordak-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6ebb8256f18659bf8430a1cea970e35148c2c8a276bc4bb1d972355b829f747c
MD5 f16c6d35ee0107ca701eab54217c4050
BLAKE2b-256 db3a7dbcdc858dea7e842777377a80981af2c0a2e0062beaa4dc29623afda5c3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page