This is the project for the group project for the course Java Enterprise.
Installation:
You need to set the following environment variables:
| Environment variable | Description | Default |
|---|---|---|
| MYSQL_HOST | The URL/IP address of the MySQL server | localhost |
| DB_DATABASE | The database that you want to connect to on the server | |
| DB_PORT | The port of the MySQL server | 3306 |
| DB_USER | Username of the database user | |
| DB_PASSWORD | Password of the database user | |
| PASSWORD | The password for the standard user | |
| MJ_EMAIL_ADDRESS | The email address of the MailJet sender | |
| MJ_PRIMARY_KEY | The primary key of the MailJet account | |
| MJ_SECRET_KEY | The secret key of the MailJet account |
After those have been set, you're good to go!
Associations
Course:
- Students (ManyToMany)
- Teacher (ManyToOne)
School:
- Principal (OneToOne)
- Students (OneToMany)
- Courses (OneToMany)
- Teachers (ManyToMany)
Role:
- Users (ManyToMany)
User:
- Roles (ManyToMany)
Endpoints & JSON
Login in with the standard user password or send a post request to /users/signup with JSON body for admin access:
{
"username": "<Username>",
"password": "<Password>",
"roles": [
"ROLE_ADMIN"
]
} Login with the same details at /swagger-ui
There you will find a complete list of all available endpoints as well as JSON bodies.
The people who worked on this project:
- Marcus Leeman
- Oscar Eriksson Stjernfeldt
- Christian Löfqvist