diff --git a/materia/migrations/0030_auto_20160429_1349.py b/materia/migrations/0030_auto_20160429_1349.py new file mode 100644 index 000000000..cfd764719 --- /dev/null +++ b/materia/migrations/0030_auto_20160429_1349.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.9 on 2016-04-29 16:49 +from __future__ import unicode_literals + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('materia', '0029_auto_20160428_1020'), + ] + + operations = [ + migrations.AlterModelOptions( + name='numeracao', + options={'ordering': ('materia', 'tipo_materia', 'numero_materia', 'ano_materia', 'data_materia'), 'verbose_name': 'Numeração', 'verbose_name_plural': 'Numerações'}, + ), + ] diff --git a/materia/models.py b/materia/models.py index 28dc52e80..15e3e2590 100644 --- a/materia/models.py +++ b/materia/models.py @@ -317,6 +317,11 @@ class Numeracao(models.Model): class Meta: verbose_name = _('Numeração') verbose_name_plural = _('Numerações') + ordering = ('materia', + 'tipo_materia', + 'numero_materia', + 'ano_materia', + 'data_materia',) def __str__(self): return _('Nº%(numero)s %(tipo)s - %(data)s') % {