Advanced Object‑Oriented Programming (AOOP) • Group 9 • Java Swing • MySQL • JasperReports
Member | Role(s) |
---|---|
Abegail Imee Enriquez | Internal QA Lead • JUnit Test Engineer • Database Architect • Project Representative |
Alvin Tubtub | External QA Lead • Documentation Lead |
Oliver Jann Klein Borre | Lead Developer • Java Swing & MySQL Integration |
The first MotorPH payroll prototype buckled under 25 users — manual CSV edits, broken formulas, zero audit trail.
This AOOP refactor delivers:
- ✅ Normalized MySQL schema — referential integrity for Attendance, Leave, Overtime, Payroll, Users.
- ✅ Role‑locked dashboards — each click filtered by account privilege.
- ✅ One‑click PDF reports — payslips & summaries via JasperReports.
- ✅ Clean layered code — POJO → DAO → Service → UI; tests on top.
Layer | Minimum | Notes |
---|---|---|
JDK | 23 (Temurin 23.x) | Compile & run |
IDE | NetBeans 23+ | Maven project auto‑imports |
DB | MySQL 8.3 | Include mysql‑connector‑j 8.4.x |
Reporting | JasperReports 6.20+ | Already in pom.xml |
OS | Windows 10/11 or modern Linux | macOS works but not QA‑certified |
Role | User ID | Password | |
---|---|---|---|
IT | U10005 |
[email protected] |
Hernandez@10005 |
HR | U10006 |
[email protected] |
Villanueva@10006 |
Manager | U10002 |
[email protected] |
Lim@10002 |
Finance | U10011 |
[email protected] |
Salcedo@10011 |
Employee | U10008 |
[email protected] |
Romualdez@10008 |
Users can log in using either their email address or their User ID.
⚠️ Use only for local testing. Replace in production.
To view or generate payslips and payroll summaries, you must choose a valid date range using the JDateChooser (or built-in calendar picker).
- Start Date: cannot be earlier than June 3, 2024
- End Date: cannot be later than December 31, 2024
⚠️ If either date falls outside this window, the system will reject the request.After selecting both dates, click Generate to compute and display your payslip or payroll report.
Open Terminal or Git Bash then type this to download:
git clone https://github.com/your‑org/motorph‑payroll.git
- Open MySQL Workbench → Server ▸ Data Import.
- Select the SQL dump from Milestone 2 SQL File → import.
- Confirm 30+ tables appear under
motorph_payroll
.
Edit src/main/java/db/DatabaseConnection.java
:
private static final String URL = "jdbc:mysql://localhost:3306/payrollsystem_db";
private static final String USER = "root";
private static final String PASSWORD = "your‑mysql‑password"; ⬅️ Please update with your own DB password
NetBeans ▸ right‑click project ▸ Clean and Build.
Unit tests pass ➜ fat JAR under target/
.
Hit
Login with the test credentials and explore.
Automation Notice:
Some tests include GUI interactions and PDF generation. These may trigger pop‑ups or open documents during execution.
When running the full test suite — especially through Clean and Build in NetBeans or batch testing tools — keep in mind:
- 🪟 Modal dialogs may appear (e.g., confirmation messages, alerts).
- 📄 Generated PDFs will open automatically and may block test progress.
Closely monitor the test execution process and:
- Dismiss modal pop-ups immediately when prompted.
- Close all opened PDF viewers once each test completes.
This ensures a smooth, uninterrupted test flow.
db/ Singleton MySQL connector
pojo/ Plain objects (Employee, Attendance, …)
dao/ CRUD interfaces
daoimpl/ JDBC implementations
service/ Business logic (validation, calculations)
ui/ Swing windows (role‑filtered)
ui/base/ Abstract Swing templates & form helpers
util/ SessionManager + misc helpers
reports/ *.jrxml Jasper templates (layout only)
test/ JUnit5 tests – NOT shipped to users
- Password change: switch it once in
DatabaseConnection.java
. - New report: drop a
.jrxml
inreports/
and call from a Service. - Extra roles: insert into
userrole
; the UI auto‑adjusts. - Unit tests:
mvn test
covers DAO + Service happy‑paths.
- 📄 Expanded System Design Documentation: https://docs.google.com/spreadsheets/d/1O2_Qsl-e7WOu_GajDM0SVfFg9hynrvFhv8UL3yjqZXo
- ✅ Testing Documentation https://docs.google.com/spreadsheets/d/1CtGctWMrtfvwRpn_sDlLcfvddDmkd6QHmhEyFHldKI8
- 💾 SQL File: https://drive.google.com/drive/folders/1a-sITa1VIOpG-iBSz1WXD7cqRmVt97yz
Fixes welcome — features need a design ticket first.
- Fork → feature branch → PR.
- Respect package boundaries; business logic lives in Services, not UI.
mvn test
must be green before review.
© 2025 MotorPH IT Group 9 — academic use permitted; commercial deployment requires written consent.
Made with ☕, deadlines, and just enough 🧂 to keep it honest.