Hello Bubble Community,
I’m working on an application that involves tracking user progress through various sessions, and I need some guidance on setting up and refining my progress tracking functionality.
Application Setup:
- Data Types:
- Session: Contains details about different sessions that users can attend or complete.
- Progress Tracker: Tracks the progress for each session per user. Key fields include:
- SessionID: Reference to the corresponding session.
- UserID: Reference to the user.
- ProgressPercentage: Numerical value representing how much of the session is completed (0-100).
- Completed: Boolean indicating whether the session is fully completed.
- User Interface:
- A repeating group lists each session available to the user. Inside each cell of this repeating group, there are:
- Session Name: Displays the name of the session.
- Progress Bar: Shows visual progress from the
Progress Tracker
.
Desired Functionality:
- When a user clicks on a session in the repeating group, I want the application to automatically update the
Progress Tracker
for the previously active session to 100% inProgressPercentage
and setCompleted
to true. This should occur before the user is directed to the newly clicked session. - Each session’s progress should be saved and easily retrievable even if the user logs out, refreshes the page, or closes the browser.
Challenges:
- I am having trouble ensuring that the progress updates are correctly saved to the database when a session is clicked. Specifically, when updating the
ProgressPercentage
to 100, it doesn’t always save as expected. - I want to ensure that the progress bars in the UI accurately reflect the latest data from the
Progress Tracker
without any lag or error.
Questions for the Community:
- How can I ensure that the progress updates are consistently saved to the database without fail?
- What are the best practices for updating a progress tracking system in real-time as the user interacts with the sessions?
- Are there any considerations I might be missing that could affect the reliability of the progress tracking system?
Any insights, examples, or guidance on how to improve this setup would be greatly appreciated. Thank you for your help!