Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Properly duplicate routine data...

Roland Geider5806f2a55554
diff --git a/wger/manager/views/routine.py b/wger/manager/views/routine.py
index 4da2ad013..aac1bf066 100644
--- a/wger/manager/views/routine.py
+++ b/wger/manager/views/routine.py
@@ -34,7 +34,6 @@ from wger.manager.models import (
SlotEntry,
)
-
logger = logging.getLogger(__name__)
@@ -87,11 +86,16 @@ def copy_routine(request, pk):
copy_config(current_entry.weightconfig_set.all(), slot_entry_copy)
copy_config(current_entry.maxweightconfig_set.all(), slot_entry_copy)
+
copy_config(current_entry.repetitionsconfig_set.all(), slot_entry_copy)
copy_config(current_entry.maxrepetitionsconfig_set.all(), slot_entry_copy)
- copy_config(current_entry.maxrepetitionsconfig_set.all(), slot_entry_copy)
+
copy_config(current_entry.rirconfig_set.all(), slot_entry_copy)
+ copy_config(current_entry.maxrirconfig_set.all(), slot_entry_copy)
+
copy_config(current_entry.restconfig_set.all(), slot_entry_copy)
+ copy_config(current_entry.maxrestconfig_set.all(), slot_entry_copy)
+
copy_config(current_entry.maxrestconfig_set.all(), slot_entry_copy)
copy_config(current_entry.setsconfig_set.all(), slot_entry_copy)