accounting v0.11.0 Accounting.Journal

Functions that write to and read from the journal.

Link to this section Summary

Link to this section Types

Link to this type accounts()
accounts() :: %{optional(account_number) => Accounting.Account.t}
Link to this type id()
id() :: atom

Link to this section Functions

Link to this function child_spec(opts)
child_spec(keyword) :: Supervisor.child_spec
Link to this function fetch_accounts(journal_id, numbers, timeout \\ 5000)
fetch_accounts(Accounting.Journal.id, [account_number], timeout) ::
  {:ok, accounts} |
  {:error, term}
Link to this function list_accounts(journal_id, timeout \\ 5000)
list_accounts(Accounting.Journal.id, timeout) ::
  {:ok, [account_number]} |
  {:error, term}
Link to this function record_entries(journal_id, entries, timeout \\ 5000)
record_entries(Accounting.Journal.id, [Accounting.Entry.t, ...], timeout) ::
  :ok |
  {:error, term}
Link to this function record_invoices(journal_id, entries, timeout \\ 5000)
record_invoices(Accounting.Journal.id, [Accounting.Entry.t, ...], timeout) ::
  :ok |
  {:error, term}
Link to this function register_account(journal_id, number, description, timeout \\ 5000)
register_account(Accounting.Journal.id, account_number, String.t, timeout) ::
  :ok |
  {:error, term}
Link to this function register_categories(journal_id, categories, timeout \\ 5000)
register_categories(Accounting.Journal.id, [atom], timeout) ::
  :ok |
  {:error, term}
Link to this function setup_account_conversions(journal_id, month, year, accounts, timeout \\ 5000)
setup_account_conversions(Accounting.Journal.id, 1..12, pos_integer, [Accounting.Account.setup, ...], timeout) ::
  :ok |
  {:error, term}
Link to this function setup_accounts(journal_id, accounts, timeout \\ 5000)
setup_accounts(Accounting.Journal.id, [Accounting.Account.setup, ...], timeout) ::
  :ok |
  {:error, term}
Link to this function start_link(opts)
start_link(keyword) :: Supervisor.on_start