Skip to content

Commit

Permalink
Merge pull request #3865 from GeotrekCE/sort_bladetype_alphabetically
Browse files Browse the repository at this point in the history
Sort bladeType alphabetically #3821
  • Loading branch information
Chatewgne authored Dec 29, 2023
2 parents 0f4da76 + 2e04602 commit 2d437d2
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ CHANGELOG
- Add rules fixture on sensitive area (#3470)
- Change condition on signage & blade to select many of them (#3847)
- Allow to set headers in requests from Parsers (#3861)
- Sort bladeType alphabetically #3821

**Documentation**

Expand Down
17 changes: 17 additions & 0 deletions geotrek/signage/migrations/0039_alter_bladetype_options.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 3.2.21 on 2023-12-21 08:47

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('signage', '0038_auto_20231023_1233'),
]

operations = [
migrations.AlterModelOptions(
name='bladetype',
options={'ordering': ('label',), 'verbose_name': 'Blade type', 'verbose_name_plural': 'Blade types'},
),
]
1 change: 1 addition & 0 deletions geotrek/signage/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ class BladeType(TimeStampedModelMixin, StructureOrNoneRelated):
class Meta:
verbose_name = _("Blade type")
verbose_name_plural = _("Blade types")
ordering = ('label',)

def __str__(self):
if self.structure:
Expand Down

0 comments on commit 2d437d2

Please sign in to comment.