Keep your bicycle healthy!
The app is deployed at https://bicycle-health-check.herokuapp.com/
The User Stories for the app are at https://trello.com/b/V2FaCV20
- Check to see if there is any user saved in Local Storage. If there is no user saved, continue with the Sign Up process. If there is a user saved, continue with the Login process below. When signing up with Strava
- Display Login for Strava
- After a successful login to Strava, the account information is returned
- Create a record in users table
- When saving access_token, make sure to encrypt the data with SECRET_KEY
- The access_type in users table will be set to 'strava'
-
When signing up without Strava
- Prompt to enter First Name, Last Name, Email Address, Password and Confirm Password
- The access_type in users table will be set to 'normal'
- Once sign up is complete, the current user is saved in the Local Storage
- Retrieve user information from the Local Storage and determine whether the user account is connected to Strava account.
- If the account is connected to Strava:
- Retrieve access_token from users table
- Decrypt the access_token
- Retrieve the latest ride information
- Add new ride activities into rides table
- For each activity, pull weather information for the date and add to conditions table
- Update parts table with new mileages
- Change part status indicator
- If there were no additional activities since the last login, just display the current status
- If the account is not connected to Strava:
- Display the current status
- User may select to enter ride information by selecting Enter Ride
- Display dialog for user to enter Date and Distance
- When Date is entered, pull weather information for the date and add to conditions table
- Update parts table with new mileages
- Change part status indicator
- User selects Add Bicycle option from the menu
- Prompt to add bicycle information
- User may add one or more bicycles
- Prompt to add various parts user would like to track from the app and its estimated mileage since the last repair/replacement
- User may add one or more parts
- Prompt to add ride with mileage
- User selects the part repaired or replaced by touching a part and selecting Repair / Replace button.
- Prompt user with the part information.
- The mileage on the part is reset.