On hover of exercise progress sparkline on new workout modal, show estimated 1rm and date of workout as a popover
This commit is contained in:
5
db.py
5
db.py
@@ -489,4 +489,7 @@ class DataBase():
|
||||
estimated_1rm = [t['estimated_1rm'] for t in topsets]
|
||||
# Get a list of all start_dates
|
||||
start_dates = [t['start_date'] for t in topsets]
|
||||
return (estimated_1rm, start_dates)
|
||||
# Create a list of messages with the structure 'estimated_1rm kg on start_date' with start_date formatted as 'dd/mm/yyyy'
|
||||
messages = [f'{t["estimated_1rm"]}kg on {t["start_date"].strftime("%d/%m/%Y")}' for t in topsets]
|
||||
|
||||
return (estimated_1rm, start_dates, messages)
|
||||
Reference in New Issue
Block a user