diff --git a/src/main/asciidoc/models/design/catalog.puml b/src/main/asciidoc/models/design/catalog.puml index 0e40943..b70f0c5 100644 --- a/src/main/asciidoc/models/design/catalog.puml +++ b/src/main/asciidoc/models/design/catalog.puml @@ -8,44 +8,68 @@ package Spring { } package Salespoint { - interface Catalog << T > Product >> + 'https://st.inf.tu-dresden.de/SalesPoint/api//org/salespointframework/catalog/Catalog.html' + interface Catalog << T > Product >> { + findByAnyCategory(categories : String) : Streamable + findByAllCategories(categories : String) : Streamable + + } interface DataInitializer interface Inventory << T > InventoryItem >> - class Product - class Quantity + class Product { + + Product(name : String, price : javax.money.MonetaryAmount, [Metric : metric]) + + getID() : Product.Identifier + '+ addCategory(category : String) : boolean' #TODO: for class Inventory + '+ removeCategory(category : String) : boolean' #TODO: for class Inventory + '+ supports(quantity : Quantity) : boolean' #TODO: for class Cart + + getCategories() : Streamable + + getName() : String + + getPrice() : @NonNull javax.money.MonetaryAmount + + } + class Quantity { + + getAmount() : @NotNull BigDecimal + } } package catering.catalog { interface CateringCatalog { + DEFAULT_SORT : Sort - + findByType(type, sort : Sort) : Iterable - + findByEventType(type) : Iterable } CateringCatalog --o CatalogController : "-catalog" CateringCatalog ..> Catalog : " Product" class CatalogController { + CatalogController() - + eventcateringCatalog(model : Model) : String - + partyserviceCatalog(model : Model) : String - + mobilebreakfast(model : Model) : String - + rentacookCatalog(model : Model) : String + + CatalogByEventategory(model : Model, form : Form) : String } CatalogController --> Inventory : "- inventory" CatalogController ..> Model : "use" + CatalogController .> CatalogForm : "use" + + class CatalogForm { + - query + + getQuery() : String + } class Consumable { - wholesalePrice - retailPrice - promotionPrice [0..1] + - wholesalePrice : javax.money.MonetaryAmount + - retailPrice : javax.money.MonetaryAmount + - promotionPrice : javax.money.MonetaryAmount + + getWholesalePrice() : javax.money.MonetaryAmount + + getPrice() : javax.money.MonetaryAmount } Consumable --|> Product class Rentable { - pricePerHour + - pricePerHour : javax.money.MonetaryAmount + - Events : Streamable + + getPrice() : javax.money.MonetaryAmount + } Rentable --|> Product } +'#TODO: to determine which Products of a Category to offer I need to retrieve information about availability of e.g. Cooks and ServicePersonel from the Users or Rentables from the Inventory' @enduml \ No newline at end of file diff --git a/src/main/asciidoc/models/design/catalog.svg b/src/main/asciidoc/models/design/catalog.svg index 19d3f6e..6c583e9 100644 --- a/src/main/asciidoc/models/design/catalog.svg +++ b/src/main/asciidoc/models/design/catalog.svg @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5e08203291f2fd3aa3c07f176fe190b5cc86a5f30c6aa93db9d452d43ed1e7fc -size 23616 +oid sha256:08b775d307e62715b0ee682912c0f817db78cb666fc2154834220db2590a256a +size 29290