better ordering of fundings
authorJan Szejko <janek37@gmail.com>
Mon, 16 Apr 2018 11:37:26 +0000 (13:37 +0200)
committerJan Szejko <janek37@gmail.com>
Mon, 16 Apr 2018 11:37:26 +0000 (13:37 +0200)
src/funding/migrations/0003_auto_20180416_1336.py [new file with mode: 0644]
src/funding/models.py

diff --git a/src/funding/migrations/0003_auto_20180416_1336.py b/src/funding/migrations/0003_auto_20180416_1336.py
new file mode 100644 (file)
index 0000000..94485d7
--- /dev/null
@@ -0,0 +1,18 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('funding', '0002_auto_20151221_1225'),
+    ]
+
+    operations = [
+        migrations.AlterModelOptions(
+            name='funding',
+            options={'ordering': ['-payed_at', 'pk'], 'verbose_name': 'funding', 'verbose_name_plural': 'fundings'},
+        ),
+    ]
index 392666f..b126c76 100644 (file)
@@ -241,7 +241,7 @@ class Funding(models.Model):
     class Meta:
         verbose_name = _('funding')
         verbose_name_plural = _('fundings')
-        ordering = ['-payed_at']
+        ordering = ['-payed_at', 'pk']
 
     @classmethod
     def payed(cls):