-
Notifications
You must be signed in to change notification settings - Fork 0
/
Erd diagram.wsd
104 lines (86 loc) · 1.48 KB
/
Erd diagram.wsd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
@startuml
!define table(x) class x << (T,#FFAAAA) >>
hide methods
hide stereotypes
table(Users) {
PK user_ID
FK wallet_ID
String name
String email
String password
String userType
}
table(Products) {
PK product_ID
String name
blob image
float price
int stock
String productCategory
}
table(Favorites) {
FK user_ID
FK product_ID
}
table(Wallets) {
PK wallet_ID
int fonds
}
table(CreditCards) {
PK creditCard_ID
FK wallet_ID
String experationdate
String cardnumber
String cvv
String nameOfCardHolder
String nameOfCard
}
table(Coupons) {
PK coupon_ID
FK wallet_ID
}
table(ProductCategorys) {
String category
blob image
}
table(SavedShoppingCarts) {
PK savedShoppingCarts_ID
FK user_ID
}
table(SavedShoppingCartsProducts){
FK savedShoppingCarts_ID
FK product_ID
int amount
}
table(Purchases) {
PK purchase_ID
FK user_ID
String date
}
table(PurchasedProducts) {
FK purchasedShoppingCarts_ID
FK product_ID
int amount
}
'medarbejdere
table(Workers) {
FK user_ID
String phoneNumber
}
table(Shifts) {
PK shift_ID
FK user_ID
String date
float period
String description
}
Wallets ||--|| Users
Wallets }o--|| CreditCards
Wallets }o--|| Coupons
Favorites ||--o{ Users
Favorites ||--o{ Products
SavedShoppingCarts ||--|{ SavedShoppingCartsProducts
Purchases ||--{ PurchasedProducts
Workers ||--|| Users
Users ||--o{ Shifts
@enduml