README.md 2.16 KB
Newer Older
Samuel Dudík's avatar
Samuel Dudík committed
1
2
# PA165 Winery Management System

Samuel Dudík's avatar
Samuel Dudík committed
3
PA165 course at MUNI Spring 2022.
4

Jakub Balga's avatar
Jakub Balga committed
5
# Build and Run Tests
6
7
8
9
10

Assuming you are in the root directory of this project:
```bash
cd winery
mvn clean install
11
mvn spring-boot:run -pl webapp
12
13
```

Ondřej Pavlica's avatar
Ondřej Pavlica committed
14
15
16
17
18
19
20
21
# Logins
## Admin
E-mail: `admin@winery.com`
Password: `admin`
## User
E-mail: `user@winery.com`
Password: `user`

Jakub Balga's avatar
Jakub Balga committed
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# How to test the REST API
- Download Insomnia or similar tool for sending HTTP requests
- Run the application (no need of login, REST API is there only for demonstration purposes)

- Get all grapes: GET http://localhost:8080/pa165/rest/grape
- Get grape with id 2: GET http://localhost:8080/pa165/rest/grape/2
- Create new variety Chardonnay: POST http://localhost:8080/pa165/rest/grape/create; body of request: {"name":"Chardonnay"}
- Change Pálava to Hibernal: POST http://localhost:8080/pa165/rest/grape/edit; body of request: {"id":1,"name":"Hibernal"}
- Delete Tramín červený: DELETE http://localhost:8080/pa165/rest/grape/delete; body of request: {"id":2,"name":"Tramín červený"}

- POST and DELETE requests does not return, inspect content of grape database by the first command


# About Project
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51

- **Name**: Winery Management System
- **Technologies**: Java 11, Spring, Hibernate, Maven
- **Developers**:
    - Ondřej Pavlica @xpavlica - _Project Leader_
    - Jakub Balga @xbalga
    - Michaela Korenková @xkorenk
    - Samuel Dudík @xdudik
- **Assigment**:
    - Create an information system that will allow a person to manage its own winery in a better way.  The main user role can manage
    the yearly wine harvest, annotating the quality, quantity of different types of grapes. Then he will manage the wines that can be
    produced depending on the type of grapes available and other ingredients. The user can also manage the list of wine bottles sold
    and stocked and available to buyers. Buyers can consult the system to buy quantities of wine bottles, also leaving feedback about
    the quality of the wine they have bought.

# Project Description
Ondřej Pavlica's avatar
Ondřej Pavlica committed
52
53
54
55

# UML Diagrams

## Use Case Diagram
Samuel Dudík's avatar
Samuel Dudík committed
56
![](docs/use_case_diagram.png)
Ondřej Pavlica's avatar
Ondřej Pavlica committed
57
58
59

## Entity-Relationship Diagram
![](docs/WineryERD.png)
Ondřej Pavlica's avatar
Ondřej Pavlica committed
60
61

## Analytical Class Diagram (Entities)
Samuel Dudík's avatar
Samuel Dudík committed
62
![](docs/WineryAnalytical.png)