Skip to content

elixir-fintech/del-phoenix-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

118 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DelExample

A sample Phoenix 1.8 application for the DoubleEntryLedger library, showcasing command-sourced double-entry bookkeeping with DaisyUI components.

Prerequisites

  • Elixir 1.17+
  • PostgreSQL 14+

Installation

mix setup

This runs deps.get, creates and migrates the database, seeds demo data, and builds assets.

Start the application

iex -S mix phx.server

Access the application at http://localhost:4000/

Seed data

The seed file (priv/repo/seeds.exs) queues commands for backend processing:

  • 1 ledger instance (ledger:1)
  • 5 account commands (EUR/USD assets, liability, equity)
  • 14 transaction commands including 3 that intentionally fail (overdraft violations, unbalanced entries)

Commands are processed asynchronously by Oban workers which create accounts, entries, balances, and balance history.

To re-seed on an existing database:

mix run priv/repo/seeds.exs

To reset everything from scratch:

mix ecto.reset

About

A basic double entry ledger integration with the phoenix framework

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors