Skip to content

Database Schema

stevenseb edited this page Aug 23, 2024 · 2 revisions

MenuableDB

Users

column name data type details
id integer not null, primary key
firstName string not null
lastName string not null
username string not null, unique
password string not null
email string not null, unique
phone string not null
address string not null
points integer
createdAt date
updatedAt date

Items

column name data type details
id integer not null, primary key
name string not null
description string not null
onMenu boolean not null
price decimal not null
quantity integer not null
measure string not null
numRatings integer not null
stars integer not null
quantityOnHand integer not null
costPerUnit decimal not null
imageFilename string not null
createdAt date
updatedAt date

Routes

column name data type details
id integer not null, primary key
deliveryDate date
createdAt date
updatedAt date

Orders

column name data type details
id integer not null, primary key
routeId integer not null
userId integer not null
orderDate date
createdAt date
updatedAt date

OrderItems

column name data type details
id integer not null, primary key
orderId integer not null
itemId integer not null
itemName string not null
itemQuantity integer not null
itemPrice decimal not null
createdAt date
updatedAt date

Reviews

column name data type details
id integer not null, primary key
itemId integer not null
userId integer not null
content string not null
createdAt date
updatedAt date
Clone this wiki locally