A robust loan management and tracking system built with Spring Boot and React. This application helps manage loans, groups, installments, and payments with a automated allocation system.
- Backend: Spring Boot 4.0+ (Java 26)
- Database: PostgreSQL
- ORM: Spring Data JPA with Hibernate
- Frontend: React (located in
/frontend) - Build Tool: Maven
The project follows a standard Spring Boot layered architecture:
- Domain Models: JPA entities representing the database schema (
Entry,Group,Payment,InstallmentDetail, etc.). - Repositories: Spring Data JPA interfaces for database abstraction.
- Services: Business logic layer (e.g.,
PaymentAllocationServicehandles the complex logic of applying payments to installments). - Controllers: REST APIs for frontend-backend communication.
- Entry: Represents a loan or financial entry.
- InstallmentDetail: Breaks down an entry into scheduled payments.
- Payment: Records of actual payments made.
- PaymentAllocation: Tracks how a single payment is distributed across various installments.
- Group/Person: Manages borrowers and organizational structures.
To run this project locally, you need to configure your PostgreSQL instance.
The application is configured to look for a database named loan_tracker.
- Open
src/main/resources/application.yml. - Update the
datasourcesection if your local settings differ:
spring:
datasource:
url: jdbc:postgresql://localhost:5432/loan_tracker
username: your_postgres_username
password: your_postgres_password # Or set the DB_PASSWORD environment variableThe current configuration uses ${DB_PASSWORD}. You can either:
- Set an environment variable named
DB_PASSWORD. - Replace
${DB_PASSWORD}directly with your password inapplication.yml.
You can run the application using Maven:
./mvnw spring-boot:runThe server will start on http://localhost:8080.
The backend is largely set up with a comprehensive REST API. The next phase involves:
- Frontend Implementation: Building the user interface in the
/frontenddirectory using React. - Integration: The project is already configured with
frontend-maven-plugin, which automatically:- Installs Node.js and npm.
- Runs
npm installandnpm run build. - Copies the production build into the Spring Boot static resources.
To work on the frontend independently:
cd frontend
npm install
npm startThis project is for internal use as part of the CS 127 Machine Problem.