From 26f4a84d0b51f83075ffd272109c9d44e099f006 Mon Sep 17 00:00:00 2001 From: Peter Stockings Date: Sat, 9 Dec 2023 20:59:50 +1100 Subject: [PATCH] Change order that plot lines are rendered so E1RM is always visible --- db.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/db.py b/db.py index 3a3c8ae..566444c 100644 --- a/db.py +++ b/db.py @@ -515,11 +515,6 @@ class DataBase(): repetitions_points = zip(repetitions_scaled, relative_positions, messages) weight_points = zip(weight_scaled, relative_positions, messages) - estimated_1rm = { - 'label': 'E1RM', - 'color': '#2ca02c', - 'points': list(estimated_1rm_points) - } repetitions = { 'label': 'Reps', 'color': '#388fed', @@ -530,6 +525,11 @@ class DataBase(): 'color': '#bd3178', 'points': list(weight_points) } + estimated_1rm = { + 'label': 'E1RM', + 'color': '#2ca02c', + 'points': list(estimated_1rm_points) + } plot_labels = zip(relative_positions, messages) @@ -538,7 +538,7 @@ class DataBase(): 'exercise_name': topsets[0]['exercise_name'], 'vb_width': vb_width, 'vb_height': vb_height, - 'plots': [estimated_1rm, repetitions, weight], + 'plots': [repetitions, weight, estimated_1rm], 'best_fit_points': list(best_fit_points), 'plot_labels': plot_labels } \ No newline at end of file