@startuml er_diagram

entity Brewery {
    PK | id: cuid <<generated>>
    --
    * name: text
    description: text
}

entity Beer {
    PK | id: cuid <<generated>>
    --
    * breweryName: text <<FK>>
    * name: text
    description: text
    * type: text
    * vol: decimal
    ibu: int
    * size: int
    * stockAmount: int
    image_url: text
}

entity Distillery {
    PK | id: cuid <<generated>>
    --
    * name: text
    description: text
}

entity Spirit {
    PK | id: cuid <<generated>>
    --
    * distilleryName: text <<FK>>
    * name: text
    description: text
    * type: text
    * vol: decimal
    * size: int
    * stockAmount: int
    image_url: text
}

entity Announcements {
    PK | id: cuid <<generated>>
    --
    * title: text
    * facebookUrl: text
}

entity Admin {
    PK | id: cuid <<generated>>
    --
    * name: text
}

Beer }o--|| Brewery
Spirit }o--|| Distillery

Brewery -[hidden]down-> Announcements
Distillery -[hidden]down-> Admin

@enduml