diff --git a/corbo/migrations/0012_auto_20200413_1854.py b/corbo/migrations/0012_auto_20200413_1854.py new file mode 100644 index 0000000..ab1f606 --- /dev/null +++ b/corbo/migrations/0012_auto_20200413_1854.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.17 on 2020-04-13 18:54 +from __future__ import unicode_literals + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('corbo', '0011_auto_20180426_1334'), + ] + + operations = [ + migrations.AlterModelOptions( + name='category', + options={'ordering': ['name']}, + ), + ] diff --git a/corbo/models.py b/corbo/models.py index fdc3efc..ee850ec 100644 --- a/corbo/models.py +++ b/corbo/models.py @@ -31,6 +31,9 @@ class Category(models.Model): help_text=_('if defined, announces will be automatically created from rss items')) ctime = models.DateTimeField(auto_now_add=True) + class Meta: + ordering = ['name'] + def __unicode__(self): return self.name