Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente | ||
eadl:bloc3:dev_av:td2 [2025/10/08 00:14] – [4.4 Optimisation des identifiants avec Tsid] jcheron | eadl:bloc3:dev_av:td2 [2025/10/08 00:18] (Version actuelle) – [4.4 Optimisation des identifiants avec Tsid] jcheron | ||
---|---|---|---|
Ligne 266: | Ligne 266: | ||
< | < | ||
<uml> | <uml> | ||
- | @startuml | + | @startuml |
- | entity | + | class Review { |
- | | + | |
- | -- | + | - rating : Integer |
- | * product_id : UUID << | + | |
- | * user_id : UUID << | + | |
- | * rating : Integer | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
} | } | ||
- | entity | + | class Product { |
- | | + | |
+ | - name : String | ||
+ | - price : BigDecimal | ||
+ | - stock : Integer | ||
} | } | ||
- | entity | + | class User { |
- | | + | |
+ | - username : String | ||
+ | - email : String | ||
} | } | ||
- | Review }o--|| Product | + | Product " |
- | Review | + | User " |
+ | |||
+ | note right of Review | ||
+ | Contraintes métier : | ||
+ | • rating ∈ [1..5] | ||
+ | • 1 review max par (user, product) | ||
+ | • verified = true si achat confirmé | ||
+ | • helpfulCount >= 0 | ||
+ | |||
+ | Tsid Generator pour l'id | ||
+ | (performance + tri chronologique) | ||
+ | end note | ||
@enduml | @enduml | ||
+ | |||
+ | |||
</ | </ |