-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathwireframe.txt
More file actions
39 lines (32 loc) · 1.17 KB
/
wireframe.txt
File metadata and controls
39 lines (32 loc) · 1.17 KB
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
Home Page
Login (maybe modal popup)
Register -> POST /api/user Send username, password
Login -> PUT /api/user Send Username, Password
Random Recipes -> GET /api/recipe
Clicking on Recipe goes to Recipe page
After Login Home Page
Get user's receipes -> GET /api/recipe/:user
Clicking on Recipe goes to Recipe page
Post Button (new page)
Form to enter receipes
Add to database -> POST /api/recipe/:user Send recipe
Go back to Home Page
Search Button (same page as user's homepage)
Get receipes from the api -> Food API
List receipes with Save option
Click Save to add receipe to database -> POST /api/recipe/:user Send recipe
SERVER ENDPOINTS
POST /api/user -> addUser(username, password)
PUT /api/user -> getUser(username) then compare
GET /api/recipe -> getAllRecipes()
GET /api/receipe/:user -> getUserRecipes(userId)
POST /api/recipe/:user -> addRecipe(userId, receipe)
ORM
addUser(username, passord) -> SQL
getUser(username) -> SQL SELECT
getAllRecipes() -> SQL (LIMIT 10)
getUserRecipes(userId) -> SQL
addRecipe(userId, receipe) -> SQL
DATABASE
login table: id, username, password
receipe table: receipeId, title, description, userId