explaingit

tahaemree/enterprise-erp

12TypeScriptAudience · developerComplexity · 4/5LicenseSetup · hard

TLDR

A multi-tenant business management system (ERP) covering accounting with Turkish e-invoice integration, inventory tracking, role-based access, and AES-256 field encryption, built with Next.js, PostgreSQL, and Redis.

Mindmap

mindmap
  root((enterprise-erp))
    Core modules
      Accounting and VAT
      Inventory tracking
      E-invoicing GIB
    Multi-tenancy
      Isolated per tenant
      Role-based access
      SSO and password auth
    Security
      AES-256 field encryption
      Row-level isolation
    Tech stack
      Next.js
      PostgreSQL
      Redis and BullMQ
    Testing
      Vitest unit tests
      Playwright E2E
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Build a SaaS platform where multiple businesses each manage their own accounting, invoices, and inventory in complete isolation from each other.

USE CASE 2

Issue legally compliant Turkish electronic invoices in real time by connecting to the government's GIB SOAP interface.

USE CASE 3

Run heavy tasks like large report generation or batch invoice processing as background jobs so users never wait for the page to respond.

USE CASE 4

Enforce fine-grained role-based permissions so employees only see the features and data their role allows.

Tech stack

TypeScriptNext.jsPostgreSQLRedisBullMQVitestPlaywright

Getting it running

Difficulty · hard Time to first run · 1h+

Requires Node.js 20+, PostgreSQL 15+, and Redis 7+ running locally, Turkish GIB e-invoice integration needs government credentials.

MIT, use freely for any purpose, including commercial projects, as long as you keep the copyright notice.

In plain English

Enterprise ERP is a business management system built for companies that want to run multiple separate organizations from a single platform. Each organization, called a tenant, gets its own isolated slice of the database so that one company's data can never be seen by another. This pattern is common in B2B software-as-a-service products where one vendor hosts many clients. The system covers several core business functions. It includes an accounting engine that handles VAT and withholding taxes, and reconciles ledger entries automatically. It also connects directly to Turkey's Revenue Administration (GIB) via a government SOAP interface, which allows businesses to issue legally compliant electronic invoices in real time. Inventory tracking is included, with low-stock alerts sent through a background job queue rather than slowing down the main application. Security is addressed at multiple layers. Personal data fields are encrypted individually using AES-256, meaning sensitive information is protected even at the database level. Access to features is controlled through role-based permissions, and authentication supports both single sign-on and traditional username/password login. The technical stack is built around Next.js for both the front end and the API layer, with PostgreSQL as the main database and Redis handling caching and background task queues. Background jobs, such as generating large reports or processing batches of invoices, run through BullMQ so they do not block user requests. The project is structured around domain-driven design, grouping accounting, inventory, and invoicing logic into separate modules. Tests are split between unit tests using Vitest and end-to-end browser tests using Playwright. It runs locally with Node.js 20 or higher, PostgreSQL 15 or higher, and Redis 7 or higher. The code is released under the MIT license.

Copy-paste prompts

Prompt 1
Using enterprise-erp as a starting point, walk me through adding a new tenant (company) and configuring their VAT settings so they can issue Turkish e-invoices through the GIB interface.
Prompt 2
I want to add a new inventory module feature to enterprise-erp. Show me how the domain-driven structure works and where to put the new logic, migrations, and tests.
Prompt 3
Explain how enterprise-erp's AES-256 field-level encryption works, show me how a sensitive field is encrypted before it's saved to PostgreSQL and decrypted when it's read.
Prompt 4
Set up BullMQ in enterprise-erp to process a new background job that sends low-stock email alerts without blocking the main request cycle.
Prompt 5
Write a Playwright end-to-end test for the enterprise-erp login flow, covering both SSO and username/password paths.
Open on GitHub → Explain another repo

← tahaemree on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.