Skip to content

maziyank/nats

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

533 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NATS — Enterprise Resource Planning System (v1.0.0-alpha)

NATS is a Next.js-based ERP system designed to handle various business functions ranging from accounting, inventory, sales, purchasing, POS, to payroll.

🌐 Lihat Dokumentasi Online

Key Features

  • Accounting: Automated general ledger, journals, and financial reports.
  • Inventory: Management of stock, warehouses, and item movements.
  • Sales & Purchasing: Complete workflow from orders to invoices.
  • Point of Sale (POS): Responsive and user-friendly cashier interface.
  • Payroll: Automated salary structure management and payslip generation.
  • AI Integration: Smart features to assist in business data analysis.

Screenshots

1776302209274 Main Dashboard View

1776302243874 Accounting Module

1776302322989 Financial Report

1776302374473 Point of Sale (POS)

Installation Guide

Follow the steps below to run NATS in your local environment.

Prerequisites

Before starting, ensure your system has the following components:

  • Node.js: Version 20.x or later.
  • NPM: Usually included with the Node.js installation.
  • PostgreSQL: The main system database.
  • Git: For source code management.

Installation Steps

1. Clone Repository

git clone <repository-url>
cd nats

2. Install Dependencies

npm install

3. Configure Environment Variables

Copy the .env.example file to .env and adjust its values:

cp .env.example .env

Ensure the DATABASE_URL variable correctly points to your PostgreSQL instance: DATABASE_URL="postgresql://user:password@localhost:5432/nats"

4. Database Preparation

Create a database in PostgreSQL:

psql -U postgres -c "CREATE DATABASE nats;"

Perform database migration and schema creation:

npx prisma generate
npx prisma migrate dev --name init

5. Seed Initial Data

Populate the database with initial data (roles, default users, etc.). Choose one of the following options:

Option A: Complete Seeding (Recommended for Testing) Includes sample products, transactions, and bulk data:

npm run prisma db seed

Option B: Minimal Seeding (Clean Start) Includes only essential data: Company Profile, Chart of Accounts, and Default Roles/Users:

npm run prisma:seed:minimal

Default Credentials:

  • Password: password123 (for all default users)
Role Email Name
Super Admin [email protected] Admin User
Accountant [email protected] John Accountant
Cashier [email protected] Jane Cashier
Manager [email protected] Mike Manager
Merchant [email protected] Sample Merchant
Customer [email protected] Sample Customer

6. Run Application

Run the development server:

npm run dev

The application can be accessed at http://localhost:3000.


Installation Using Docker (Optional)

If you want to run the application using Docker Compose:

docker-compose up -d

After the containers are running, initialize the database:

docker-compose exec app npx prisma migrate deploy
# Run complete seed
docker-compose exec app npm run prisma db seed

# OR run minimal seed
docker-compose exec app npm run prisma:seed:minimal

License

This project is licensed under LICENSE.

About

NATS | Open Source Business and Accounting Software

Resources

License

Stars

19 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors

Languages