fix morceau ordering
This commit is contained in:
parent
50f888a07c
commit
a7851ff123
2 changed files with 19 additions and 1 deletions
18
partitions/migrations/0007_auto_20220118_1542.py
Normal file
18
partitions/migrations/0007_auto_20220118_1542.py
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
# Generated by Django 2.2.24 on 2022-01-18 14:42
|
||||||
|
|
||||||
|
from django.db import migrations
|
||||||
|
import django.db.models.functions.text
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('partitions', '0006_auto_20220118_1525'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterModelOptions(
|
||||||
|
name='partitionset',
|
||||||
|
options={'ordering': ('category', django.db.models.functions.text.Lower('nom')), 'verbose_name': 'Morceau', 'verbose_name_plural': 'Morceaux'},
|
||||||
|
),
|
||||||
|
]
|
|
@ -71,7 +71,7 @@ class PartitionSet(models.Model):
|
||||||
class Meta:
|
class Meta:
|
||||||
verbose_name = _("Morceau")
|
verbose_name = _("Morceau")
|
||||||
verbose_name_plural = _("Morceaux")
|
verbose_name_plural = _("Morceaux")
|
||||||
ordering = (Lower("nom"),)
|
ordering = ("category",Lower("nom"),)
|
||||||
|
|
||||||
|
|
||||||
from datetime import date as ddate
|
from datetime import date as ddate
|
||||||
|
|
Loading…
Reference in a new issue