Skip to content

Commit

Permalink
Update[Readme]: Add more detailed information about the project
Browse files Browse the repository at this point in the history
  • Loading branch information
Fredrik Marjoni committed Apr 21, 2026
1 parent 3748fc5 commit 1b22059
Showing 1 changed file with 121 additions and 18 deletions.
139 changes: 121 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Help-Me-Help - IDATT1005 Team 5 Portofolio Project Spring 2026 :octocat:
# Help-Me-Help - IDATT1005 Team 5 Portofolio Project Spring 2026 :octocat:

[//]: # (TODO: Fill inn your name and student ID)
[//]: # (TODO: Mappe-2025-Marjoni-fj)
Expand All @@ -14,7 +14,16 @@
## Project description💻

[//]: # (TODO: Write a short description of your project/product here.)
This Java-based application, developed using Maven...
Help-Me-Help (HmH) is a Java desktop application, developed using Maven, designed to help users donate money to legitimate charitable organizations and emergency relief initiatives. The application fetches verified organization data from Innsamlingskontrollen (IK), a non-profit foundation that verifies fundraising activities. Users can create profiles, track their donation history, and browse organizations by status (approved/pending). The application prioritizes security, data persistence, and an intuitive user experience following Don Norman's interaction design principles.

## Key Features

- User authentication and profile management
- Browse verified and pending organizations with descriptions and logos
- Make donations to organizations
- View donation history
- Data persistence using H2 database
- Web scraping of organization information (descriptions, logos) from external sources

## Project structure 📁

Expand All @@ -25,19 +34,106 @@ All source files are stored under the `src` directory.
### Main Package Structure (`src/main`)

<pre>

src/main/java/edu/group5/app/
├── App.java (JavaFX Application entry point)
|
├── control/ (Controllers - business logic)
│ ├── AuthController.java (User login/signup handling)
│ ├── DonationController.java (Donation processing)
│ ├── NavigationController.java (Page navigation)
│ └── OrganizationController.java (Organization data access)
|
├── model/ (Business entities & repositories)
│ ├── organization/
│ │ ├── Organization.java (Organization entity)
│ │ ├── OrganizationRepository.java (Data access for organizations)
│ │ ├── OrganizationService.java (Business logic)
│ │ └── OrganizationScraper.java (Web scraping - descriptions & logos)
│ ├── user/
│ │ ├── User.java (User base class)
│ │ ├── Customer.java (Customer implementation)
│ │ ├── UserRepository.java (Data access for users)
│ │ └── UserService.java (User authentication & registration)
│ ├── donation/
│ │ ├── Donation.java (Donation entity)
│ │ ├── DonationRepository.java (Data access for donations)
│ │ └── DonationService.java (Donation processing)
│ ├── wrapper/
│ │ ├── DbWrapper.java (H2 database connection & operations)
│ │ └── OrgApiWrapper.java (Innsamlingskontrollen API client)
│ ├── AppState.java (Global application state)
│ ├── Repository.java (Base repository interface)
│ └── DBRepository.java (Database repository interface)
|
├── view/ (JavaFX UI components)
│ ├── loginpage/
│ │ ├── LoginPageView.java
│ │ ├── SignUpPageView.java
│ │ ├── LoginHeader.java
│ │ └── loginpage.css
│ ├── homepage/
│ │ └── HomePageView.java
│ ├── causespage/
│ │ ├── CausesPageView.java
│ │ ├── OrganizationCard.java
│ │ └── causespage.css
│ ├── organizationpage/
│ │ ├── OrganizationPageView.java
│ │ └── organizationpage.css
│ ├── donationpage/
│ │ ├── DonationPageView.java
│ │ ├── PaymentCompletePageView.java
│ │ └── donationpage.css
│ ├── userpage/
│ │ └── UserPageView.java
│ ├── aboutuspage/
│ │ └── AboutUsView.java
│ └── Header.java
|
└── utils/
└── ParameterValidator.java (Input validation utilities)

src/main/resources/
├── header/
│ └── images/
│ └── hmh-logo.png
├── loginpage/
│ └── loginpage.css
├── homepage/
│ └── homepage.css
├── causespage/
│ └── causespage.css
├── organizationpage/
</pre>

[//]: # (TODO: Describe the structure of your project here. How have you used packages in your structure. Where are all sourcefiles stored. Where are all JUnit-test classes stored. etc.)

### 📦 Package Responsibilities

#### Models
#### Models: Business logic and data entities

- `Organization`: Represents a charity/relief organization with status, logo, description
- `User` & `Customer`: User profiles with authentication
- `Donation`: Records of user donations
- Services and Repositories implement the business logic and data access layers

#### Controller
#### Controller: Bridge between UI and business logic

#### View
- `AuthController`: Handles user login/registration with password hashing (BCrypt)
- `OrganizationController`: Manages organization data retrieval and caching
- `DonationController`: Processes donations and updates user history
- `NavigationController`: Coordinates page navigation

#### Utils
#### View: JavaFX UI components

- Login/signup pages with form validation
- Organization browsing with filtering (approved/pending)
- Donation flow with payment confirmation
- User profile and donation history

#### Utils: Helper functions

- `ParameterValidator`: Validates null, empty, and positive values

### JUnit Tests (`src/test`)

Expand All @@ -49,9 +145,9 @@ The JUnit tests are stored under `src/test` and mirror the main package structur

The project uses the standard Maven directory structure, which ensures:

* clean separation of source and test files
* compatibility with IDEs such as IntelliJ, VS Code, and Eclipse
* maintainability and easy future extensions (e.g., persistence or additional views)
- clean separation of source and test files
- compatibility with IDEs such as IntelliJ, VS Code, and Eclipse
- maintainability and easy future extensions (e.g., persistence or additional views)

---

Expand All @@ -69,9 +165,10 @@ What is the input and output of the program? What is the expected behaviour of t

**Requirements:**

* Java JDK 25
* Maven
* IDE (Ideally IntelliJ or VSCode with Java Extension Pack)
- Java JDK 25
- Maven
- IDE (Ideally IntelliJ or VSCode with Java Extension Pack)

**Steps:**

1. **Clone repository**
Expand All @@ -94,24 +191,30 @@ What is the input and output of the program? What is the expected behaviour of t
5. **Input and Output**
* Input:
* Output:
- Input: User interactions (login, organization selection, donation amount)
- Output: JavaFX UI displaying organizations, user profiles, donation confirmations
1. **Excpected behavior:**
The program allows the user to:
<li>Login/signup with validation</li>
<li>Browse approved organizations from Innsamlingskontrollen API</li>
<li>View organization details (description, logo, status)</li>
<li>Complete donation workflow</li>
<li>View donation history in user profile</li>
<li>Graceful error handling with user-friendly messages</li>
---
## How to run the tests 🧪
This project uses JUnit 5 for unit testing.
All test classes mirror the main package structure and are stored in `src/test`
* ### Open the Project
- ### Open the Project
Open VS Code and select **File > Open Folder**, navigating to the root folder of the project (containing `pom.xml`).
* ### Run all tests
- ### Run all tests
To execute the full test suite, run:
Expand All @@ -127,7 +230,7 @@ This command:

---

* ### Viewing test results
- ### Viewing test results

After the tests finish, Maven creates detailed reports here:
`target/surefire-reports/`
Expand Down

0 comments on commit 1b22059

Please sign in to comment.