Add better post ordering

This commit is contained in:
Nathan Chapman 2022-07-22 13:16:02 -06:00
parent 3d6afc6625
commit cfd708f158
2 changed files with 18 additions and 1 deletions

View File

@ -0,0 +1,17 @@
# Generated by Django 4.0.6 on 2022-07-22 19:15
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('core', '0007_alter_post_recipients'),
]
operations = [
migrations.AlterModelOptions(
name='post',
options={'ordering': ['-updated_at', '-created_at']},
),
]

View File

@ -149,4 +149,4 @@ class Post(models.Model):
return self.title
class Meta:
ordering = ['-updated_at']
ordering = ['-updated_at', '-created_at']