This project is a continous build of the internal web page specifically developed for Singsaker Studenterhjem. The web page includes functionality for assigning work shifts, doing room distibution, administrating seniority, and much more.
These instructions will give you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on deploying the project on a live system.
Requirements for the software and other tools to build, test and push
- You will need a working copy of the MySQL database running locally on your machine or a connection URL a working MySQL database.
A step by step series of examples that tell you how to get a development environment running
Clone the repository to your local machine
git clone https://github.com/singsaker/intern.git
Install dependencies for both frontend (.intern/frontend) and backend (.intern/backend)
npm install
Create .intern/backend/.env
APP_SECRET={SECRET PASSWORD}
DATABASE_URL="mysql://USERNAME:PASSWORD@URL:PORT/DATABASE"
ENVIORNMENT="dev"
DB_ENV="testing"
Initiate prisma (from .intern/backend)
npx prisma init
Introspect database
npx prisma db pull
Generate prisma client
npx prisma generate
Run in developement mode
For both backend and frontend
npm run dev
localhost:3000 is the URL for the frontpage and localhost:4000 is a URL for doing backend calls in GraphQL.
Test backend by opening localhost:4000 and run the following
query {
hentBeboere {
id
fornavn
etternavn
}
}
- Prisma - Used as ORM for MySQL
- Apollo with GraphQL - Used as server and query language
- NextJS - React framework for production
- Material-UI - Used as UI library
- React Redux - Used as state container
- Kevin Nordnes - Project leader - LinkedIn
- Kaspar Paus Græsdal - Developer
- Mathias Raa - Developer
- Daniel Løvbrøtte Olsen - Developer