Skip to content

Commit

Permalink
Merge pull request #47 from BU-Spark/alex-final-fixes
Browse files Browse the repository at this point in the history
Alex final fixes
  • Loading branch information
alexjmiller5 authored Dec 16, 2024
2 parents 2f57a10 + bf50da1 commit b3335db
Show file tree
Hide file tree
Showing 7 changed files with 146 additions and 108 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Install Dependencies & Build

on:
push:
branches:
- main
- dev
pull_request:
branches:
- main
- dev

jobs:
test-client-build:
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 'node'
cache: 'npm'

- name: Install Dependencies
working-directory: ./client
run: npm install

- name: Run Build
working-directory: ./client
run: npm run build
128 changes: 112 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,123 @@
[![Netlify Status](https://api.netlify.com/api/v1/badges/168b2ed1-4784-4179-b85b-84a67618a35e/deploy-status)](https://app.netlify.com/sites/bu-csc-dev/deploys)

# BU CSC Hours Tracker
An application that connects BU students with nonprofit organizations looking for volunteers and records the data related to hours volunteered by individual, organization, college, and university.

# See it deployed
[https://bu-csc-dev.netlify.app/](https://bu-csc-dev.netlify.app/)
Throughout 2024, our team has been developing BU CSC Hours Tracker. Its mission is to connect BU students with nonprofit organizations.

## **Description**

BU CSC Hours Tracker is an application designed to connect BU students with nonprofit organizations looking for volunteers and record the data related to hours volunteered by the individual, organization, college, and university.

It aims to address streamlining the volunteering process by providing a platform for students to connect with non-profits and volunteering opportunities, providing background checks and forms, as well as documenting students’ completed hours.

## **Key Features**

* **Student Volunteers**: Students can track their event applications, volunteer hours, submit forms, browse volunteering events, and apply/waitlist for events.
* **Administrators**: Admins can approve volunteer hours, approve events, and receive forms.
* **Third-party**: Third-party organizations can submit/manage events, approve/verify hours, manage organization information, and upload forms.

---

## **Technical Architecture**

### Tech Stack

* Frontend: Next.js
* Backend: Next.js, Docker
* Database: Prisma, PostgreSQL
* Deployment: Render.com ([https://se-bu-csc-hours-tracking.onrender.com/](https://se-bu-csc-hours-tracking.onrender.com/))
* Render.com was used to easily provide the client with a navigable demo; it is not necessarily ideal for the final app
* Other: Clerk (for user authentication)

---

## **Getting Started**

### Prerequisites

Before starting, ensure the following are installed:

* Node
* Docker

Optional

* pgAdmin (or any postgres database client)

Also make sure to have a .env file with secrets from the project Google doc. Place it in /client.

### **Running the Application Locally**

`cd client`

`npm install`

`docker compose up`: spin up a local instance of postgres to avoid using the production database

`npx prisma migrate deploy` (run `npx prisma studio` if you want to see the contents)

`npm run dev`

**To build the frontend for deployment**:

`npm run build`

---

## **Directory Structure**

```
se-bu-csc-hours-tracking/
├── client/
│ └── .next/
│ └── node\_modules/
│ └── public/: public assets
│ └── src/: source code
│ └── \_common/: common styles for the application
│ └── app/: core Next.js app using the app router
│ │ └── \_utils: utility functions
│ │ └── (admin)/admin: administrator view
│ │ └── (third-party)/third-party: third party organization view
│ │ └── (user)/user: student volunteer view
│ │ └── api/: API routes
│ │ └── auth/sso-callback/page.tsx: post-authentication routing page
│ │ └── login/page.tsx: login page
│ │ └── unauthorized/page.tsx: redirect for unauthorized users
│ │ └── welcome/page.tsx: welcome page
│ └── components/: common application components
│ └── interfaces/interfaces.ts: Typescript interfaces
│ └── lib/: library of common functions
│ └── prisma/: database schema and migrations
│ └── middleware.ts: redirects different users to different pages
│ └── .env: secrets and environment variables (located in the PD)
├──README.md
├──/netlify: Serverless function for sending emails
├──/prisma: Database access for netlify serverless functions
```

## **Known Bugs and Issues**

# To Run Locally
`cd client` <br/>
`npm install` <br/>
`docker compose up` (if this is your first time) <br/>
`npx prisma migrate deploy` (run `npx prisma studio` if you want to see the contents) <br/>
`npm run dev` <br/>
* There is no Netlify account, so the email reminders aren’t deployed and therefore aren’t active

# .env
View the Product Description. Place inside `/client`
---

# Contributors
Owen Mariani (owenm-26) <br/>
Alessandra Lanz (alessandralanz)<br/>
## **Future Work**

* Third-party settings page uploading forms to google cloud for storage. Use S3 buckets
* Admin management of last minute registrations and capability to get off the waitlist
* Dual-use accounts where users can be volunteers as well as third party organizers
* Confirmation and reminder emails for event and waitlist registrations with calendar invites
* Third party collaboration mechanism for third party users to collaborate on volunteer events
* See more details on the [notion product backlog](https://www.notion.so/fffa3b1ea9418147ab49e2582f3077d8?v=fffa3b1ea9418102a0b5000c75102abe&pvs=4)

---

## **Team (Fall 2024\)**

* Jasper Hoong \- <[email protected]>
* Alexander Miller \- <[email protected]>
* Thomas Nguyen \- <[email protected]>
* Jeffrey Zhou \- [[email protected]](mailto:[email protected])

**Past Contributors**

* Owen Mariani (owenm-26)
* Alessandra Lanz (alessandralanz)
18 changes: 0 additions & 18 deletions client/README.md

This file was deleted.

43 changes: 0 additions & 43 deletions client/src/app/_utils/columns.ts

This file was deleted.

4 changes: 0 additions & 4 deletions client/src/constants.ts

This file was deleted.

26 changes: 0 additions & 26 deletions client/src/types/next-auth.d.ts

This file was deleted.

2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ services:
postgres:
image: postgres:15-alpine
ports:
- 5433:5433 # enables connecting locally via psql
- 5432:5432 # enables connecting locally via psql
environment:
POSTGRES_DB: hour-tracker
POSTGRES_HOST_AUTH_METHOD: trust

0 comments on commit b3335db

Please sign in to comment.