A comprehensive financial management application built with Next.js, Drizzle ORM, and PostgreSQL.
- Dashboard: Overview of financial metrics
- Expense Management: Track and categorize business expenses
- Income Tracking: Monitor revenue streams
- Asset Management: Catalog and track company assets
- Investment Portfolio: Manage investments and track performance
- Document Storage: Store and organize financial documents
- Frontend: Next.js 15 with App Router
- Styling: Tailwind CSS with shadcn/ui components
- Backend: Next.js API Routes
- Database: PostgreSQL with Drizzle ORM
- Authentication: Better Auth
- Deployment: Docker
- Node.js 18+
- Docker and Docker Compose
- PostgreSQL (via Docker)
- 
Clone the repository: git clone <repository-url> cd finance-dashboard 
- 
Install dependencies: npm install 
- 
Set up environment variables: cp .env.example .env # Update .env with your configuration
- 
Start the database: npm run db:up 
- 
Run database migrations: npm run db:push 
- 
Seed the database with initial data: npm run db:seed 
- 
Start the development server: npm run dev 
The application will be available at http://localhost:3000
├── app/                 # Next.js app router pages
│   ├── dashboard/       # Dashboard pages
│   ├── sign-in/         # Sign in page
│   ├── sign-up/         # Sign up page
│   └── api/             # API routes
├── components/          # React components
├── db/                  # Database schema and utilities
├── lib/                 # Utility functions
├── scripts/             # Helper scripts
├── public/              # Static assets
├── styles/              # Global styles
└── drizzle/            # Database migrations
The application uses the following tables:
- user: User authentication and profiles
- category: Categorization for transactions, assets, and investments
- transaction: Income and expense records
- asset: Company assets (equipment, property, etc.)
- investment: Investment portfolio
- document: Financial documents
- GET /api/dashboard- Get financial summary
- GET /api/categories- Get all categories
- POST /api/categories- Create a new category
- GET /api/categories/:id- Get a specific category
- PUT /api/categories/:id- Update a category
- DELETE /api/categories/:id- Delete a category
- GET /api/transactions- Get all transactions
- POST /api/transactions- Create a new transaction
- GET /api/transactions/:id- Get a specific transaction
- PUT /api/transactions/:id- Update a transaction
- DELETE /api/transactions/:id- Delete a transaction
- GET /api/assets- Get all assets
- POST /api/assets- Create a new asset
- GET /api/assets/:id- Get a specific asset
- PUT /api/assets/:id- Update an asset
- DELETE /api/assets/:id- Delete an asset
- GET /api/investments- Get all investments
- POST /api/investments- Create a new investment
- GET /api/investments/:id- Get a specific investment
- PUT /api/investments/:id- Update an investment
- DELETE /api/investments/:id- Delete an investment
- GET /api/documents- Get all documents
- POST /api/documents- Create a new document
- GET /api/documents/:id- Get a specific document
- PUT /api/documents/:id- Update a document
- DELETE /api/documents/:id- Delete a document
- 
Build the Docker image: npm run docker:build 
- 
Start the application: npm run docker:up 
- 
Stop the application: npm run docker:down 
- Generate migrations: npm run db:generate
- Push schema changes: npm run db:push
- Start database studio: npm run db:studio
- Lint code: npm run lint
- Format code: npm run format(if configured)
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a pull request
This project is licensed under the MIT License.