Skip to content

New plugin: grit-accounting — double-entry ledger for ERP / billing / marketplace kits #63

@MUKE-coder

Description

@MUKE-coder

ERP, billing platforms, marketplaces with platform fees, neobanks, even subscription SaaS with revenue recognition — all need a double-entry accounting layer (Chart of Accounts + balanced journal entries + reversal-only corrections). It's not hard to build but it's exacting (every business event posts balanced debits + credits in one transaction, never edit historical postings).

The ERP-lite kit I'm planning needs this; right now I'm writing it from scratch in the build prompt. It's ~400 lines of Go and would be perfect as a plugin.

Proposed fix:
New grit-accounting plugin:

  • ChartOfAccount (Asset / Liability / Equity / Income / Expense)
  • Journal + JournalLine with balance enforcement at the DB level (DB constraint: SUM(debit) − SUM(credit) = 0 per journal)
  • Posting helpers like accounting.PostSale(...), accounting.PostStockReceipt(...), etc.
  • shopspring/decimal for all money fields
  • Reports interface (callers extend with their P&L / Balance Sheet templates)

Pairs naturally with grit-export for the PDF / Excel renderers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions