Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 77 additions & 0 deletions diagram.puml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
@startuml
'https://plantuml.com/class-diagram

skinparam linetype ortho

entity "Movie" as movie {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* title : String
genre : String
year : int
runtime : int
}

entity "Screen room" as screen {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* name : String
capacity : int
}

entity "Screening" as screening {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* movie : Movie
* screen : Screen
* startTime : Date
price : decimal
}

entity "Customer" as customer {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* name : String
}

entity "Contact" as contact {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* customer : Customer
email : String
phone : String
}

entity "Ticket" as ticket {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* screening : Screening
* customer : Customer
seat : String
}

entity "Admin" as admin {
* int : id <<generated>>
* createdAt : Date
* updatedAt : Date
* name : String
* email : String
* password : String <<hashed>>
--
manages the movies and screenings,\nis not a customer
}


movie ||--o{ screening
screen ||--o{ screening
screening ||--o{ ticket
customer ||--o{ ticket
customer ||--|{ contact

@enduml
Binary file added er-diagram.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 9 additions & 1 deletion user-stories.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
- As a customer, so I can receive my tickets, I want to provide my contact information.
- As a customer, so I can decide which movie I want to watch, I want to see a list of movies.
- As an admin, so I can manage the movies shown at the cinema, I want to update the list of movies.
- As a customer, so I can pick the best seat, I want to reserve a seat of my choice.
- As a customer, so I can know the showtimes, I want to see the schedule of the movies.
- As a customer, so I can know the price, I want to see the price of the tickets.
- As an admin, so I can manage the movies shown at the cinema, I want to update the list of movies.
- As an admin, so I can manage the schedule of the movies, I want to update the schedule of the movies.
- As an admin, so I can manage the price of the tickets, I want to update the price of each screening.
- As an admin, so that my account is secure, I would like to sign in using an email address and password.

![er-diagram.png](er-diagram.png)