Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Sort routines first by start date

Roland Geider1a905d049932
diff --git a/wger/manager/migrations/0018_flexible_routines.py b/wger/manager/migrations/0018_flexible_routines.py
index 9e92a5ee3..afe4e4c4a 100644
--- a/wger/manager/migrations/0018_flexible_routines.py
+++ b/wger/manager/migrations/0018_flexible_routines.py
@@ -400,7 +400,7 @@ class Migration(migrations.Migration):
),
],
options={
- 'ordering': ['-created'],
+ 'ordering': ['-start', '-created'],
},
),
migrations.AddField(
diff --git a/wger/manager/models/routine.py b/wger/manager/models/routine.py
index 3ef8cf737..41a503e7c 100644
--- a/wger/manager/models/routine.py
+++ b/wger/manager/models/routine.py
@@ -55,6 +55,7 @@ class Routine(models.Model):
class Meta:
ordering = [
+ '-start',
'-created',
]