When a user completes a habit, add a row to it indicating a new training session.
This is the training session schema for the internal app.
const trainingSession = {
user_id: ... // primary key
item_id: `training_session-${uuidv4()}`, // sort . key
trainingType: 'external', // this is always 'external'
trainedFor: 3600 // integer in seconds
topic: 'name of habit', // name of the session should probably just be the name of the habit
sourceApplication: 'habit-loop', // this should always be habit-loop
rating: 5 // integer from 1-5
links: ["https://google.com"] // array of urls
}
A new method in dynamo should be created under the user model for now. When a user completes a habit call this dynamo method.
There will be a separate issue for the front-end portion but know that we may have to add some additional information to habit creation to get some of the information.
When a user completes a habit, add a row to it indicating a new training session.
This is the training session schema for the internal app.
A new method in dynamo should be created under the user model for now. When a user completes a habit call this dynamo method.
There will be a separate issue for the front-end portion but know that we may have to add some additional information to habit creation to get some of the information.