-
Enter application
- User types his name
- Ham looks for the user
- If User exists Ham returns recent activities
- If User DOESN'T exist Ham returns a notification
-
Check recent Facts
- User enters the application
- Ham shows the last ten Facts
-
Create Category
- User press "New Category" button
- Ham shows input to set a name
- User types a name and accepts or cancel the process
- Ham validates non existent categories with that name and store it on DB
- Ham notifies the user a new Activity was created
-
Start a log Fact
- User could select a Category
- User selects an Activity and writes a description and presses "Start Fact" button
- Ham creates a new Fact with the current time
- Ham notifies the user a new Fact was started
-
Stop a log Fact
- User presses stop button
- Ham updates the end time and finishes current activity
- Ham notifies the user the current Fact was ended
-
Show current Fact
- Ham shows current activity's name
-
Category
- Name
-
Activity
- Name
- Category
- Deleted
-
Tag
- Name
-
Fact
- Activity
- Start
- End
- Description
- Tags
-
User
- Name
- Facts
Route | HTTP Verb | Description |
---|---|---|
/api/categories | GET | Get all categories |
/api/categories | POST | Create a category |
/api/categories/:category_name | DELETE | Delete a category |
/api/activities | GET | Get all activities |
/api/activities | POST | Create an activity |
/api/activities/:activity_id | GET | Get a single activity |
/api/tags | GET | Get all tags |
/api/tags | POST | Create a tag |
/api/facts | GET | Get all facts |
/api/facts | POST | Create a fact |
/api/fact/:fact_id | GET | Get a single fact |
/api/fact/:fact_id | PUT | Update a single fact |
/api/user/fact/ | GET | Get current fact |
/api/user/facts/ | GET | Get last 10 facts |