Open RunpengNie opened 1 year ago
The basic functionalities we should have:
Allow users to register an account or log in if they already have one.
User Profile:
Exercise Entry:
Exercise Tracking:
Goal Setting and Tracking
Reports and Insights:
Privacy and Security:
Notifications and Reminders:
`Option for now 'means we don't need to implement it now, but we need to consider code scalability for these features during design.
Any thoughts? @TonyLiu836 @VincentXiao997
@Junzhou-712 Check this post and feel free to share your ideas.
Looks good! I think it's quite a comprehensive list of functionalities.
Some more optional QOL features that I think might be useful for user:
Looks good! I think it's quite a comprehensive list of functionalities.
Some more optional QOL features that I think might be useful for user:
- Allow user to track weight/fat percentage/etc over time.
- Recommend alternative variations of exercises if user doesn't have access to certain equipment.
- Timer to time rest period between sets.
Good ideas, I will add them to our future design!
// class design
User class{
String name;
String email;
String phoneNumber;
String location;
String gender;
double height;
double weight;
double bodyFatPecentage;
}
WorkoutEvent class{
DateTime date;
Duration/Period duration;
List<IExerciseEvent> exercises;
}
IExerciseEvent interface{
Duration/Period duration;
String additionalNotes;
}
EnumType DistanceUnit{
mile;
kilometer;
meter;
}
Cardio class: implements IExerciseEvent interface{
String name;
double distance;
DistanceUnit unit;
}
EnumType WeightUnit{
pound;
kilogram;
}
Strength class: implements IExerciseEvent interface{
String name;
double weight;
WeightUnit unit;
int reps;
}
Flexibility class: implements IExerciseEvent interface{
String name;
}
Custom class: implements IExerciseEvent interface{
String name;
double distance;
DistanceUnit unit;
double weight;
WeightUnit unit;
int reps;
}
// functionality desgin:
CreateWorkoutEvent()
DeleteWorkoutEvent()
UpdateWorkoutEvent()
SearchWorkoutEvent()
CreateExerciseEvent()
DeleteExerciseEvent()
UpdateExerciseEvent()
SearchExerciseEvent()
CreateCustomizedExecriseType()
DeleteCustomizedExecriseType()
CreateCustomizedExecriseEvent()
DeleteCustomizedExecriseEvent()
UpdateCustomizedExecriseEvent()
SearchCustomizedExecriseEvent()
TrackTrainingHistory()
TrackUserStatus()
@VincentXiao997 @Junzhou-712 let me know if you have any questions!
Looks like we haven't covered the type class so far. I think we still need a ExerciseType cls to store the names to allow user to specify whether the activity was cardio, strength training, or flexibility training . For this feature, we don't need a series of events instead of a series of types.
Update: Sounds good
Hi guys, the first PR of this issue has been merged, thank you for your effort! Now we want to push our development progress, and next step is our model/class design.
@TonyLiu836 Could you please implement User
, DistanceUnit
, WorkoutEvent
and WeightUnit
? After you finish, please make sure your PR name contains 7.2 and mention this issue in your PR page.
@Junzhou-712 Could you please implement IExerciseEvent
, Cardio
, Strength
, Flexibility
and Custom
? After you finish, please make sure your PR name contains 7.3 and mention this issue in your PR page.
int id(PK),
varchar/string name,
varchar/string email,
varchar/string phoneNumber,
varchar/string gender,
double height,
double weight,
double bodyFatPecentage,
int id(PK),
int UserId(FK to user table),
Date date,
DateTime startTime, (nullable)
DateTime endTime,(nullable)
int duration(constraint),
int id(PK),
int WorkoutEventID(FK to WorkoutEvent table),
int SportId(FK to PredefinedExercise table),
int disance,
int weight,
int rep,
int id(PK),
varchar/string sportName(UQ constraint),
int TypeId (FK to ExerciseType table),
boolean containsDisance, true
boolean containsWeight, true
boolean containsRep, true
int id(PK),
varchar/string sportName(UQ constraint),
boolean containsDisance, true
boolean containsWeight, true
boolean containsRep, true
User Model
Number id(PK),
string name,
string email,
string phoneNumber,
string gender,
double height,
double weight,
double bodyFatPecentage,
WorkoutEvent Model
Number id(PK),
Number UserId(FK to user table),
Date date,
DateTime startTime, (nullable)
DateTime endTime,(nullable)
Number duration(constraint),
List<ExerciseEvent>
ExerciseEvent Model
Number id(PK),
Number WorkoutEventID(FK to WorkoutEvent table),
Number SportId(FK to PredefinedExercise table),
Number disance,
Number weight,
Number rep,
<!-- PredefinedSport table is a set of rules stored in AWS Redis -->
PredefinedSport JSON model {
"id": Number,
"sportName": String,
"TypeId": Number,
"containsDistance": String,
"containsWeight": String,
"containsRep": String
}
CustomizedSport table
Number id(PK),
varchar/string sportName(UQ constraint),
boolean containsDisance, true
boolean containsWeight, true
boolean containsRep, true
Hey folks, I have updated the recent program logic. A debrief for the change is 1. we use a list to store ExerciseEvent in accordance with the logic of NoSQL. 2. For the PredefinedSport, we combined the suggestions from @VincentXiao997 and @RunpengNie which is designing a batch of JSON data stored in embedded Redis, thus we can maintain them by JSON configs instead of SQL script.
User Model Number id(PK), string name, string email, string phoneNumber, string gender, double height, double weight, double bodyFatPecentage, WorkoutEvent Model Number id(PK), Number UserId(FK to user table), Date date, DateTime startTime, (nullable) DateTime endTime,(nullable) Number duration(constraint), List<ExerciseEvent> ExerciseEvent Model Number id(PK), Number WorkoutEventID(FK to WorkoutEvent table), Number SportId(FK to PredefinedExercise table), Number disance, Number weight, Number rep, <!-- PredefinedSport table is a set of rules stored in AWS Redis --> PredefinedSport JSON model { "id": Number, "sportName": String, "TypeId": Number, "containsDistance": String, "containsWeight": String, "containsRep": String } CustomizedSport table Number id(PK), varchar/string sportName(UQ constraint), boolean containsDisance, true boolean containsWeight, true boolean containsRep, true
Hey folks, I have updated the recent program logic. A debrief for the change is 1. we use a list to store ExerciseEvent in accordance with the logic of NoSQL. 2. For the PredefinedSport, we combined the suggestions from @VincentXiao997 and @RunpengNie which is designing a batch of JSON data stored in embedded Redis, thus we can maintain them by JSON configs instead of SQL script.
LGTM, since I am not an expert on DynamoDB, I think Vincent's ideas are essential to us, what do you think @VincentXiao997 ?
PredefinedSport could be more flexible if we store them in the db as we can modify/create/delete them without deployment. I agree with your idea that customized sport templates should be stored in local table. nit, should we change PredefinedSport
and CustomizedSport
to PredefinedSportTemplate
and CustomizedSportTemplate
for better readability?
PredefinedSport could be more flexible if we store them in the db as we can modify/create/delete them without deployment. I agree with your idea that customized sport templates should be stored in local table. nit, should we change
PredefinedSport
andCustomizedSport
toPredefinedSportTemplate
andCustomizedSportTemplate
for better readability?
Both tables will store actual types of sports rather than templates, so I think the existing table names are already accurate enough.
Design the core program logic: the main functionalities. Add the functionalities descriptions and details to Design Document.