diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2025-09-17 15:24:11 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2025-09-22 16:44:59 +0200 |
commit | 0020350e9b82f01a1518fd78a32ce12be018a216 (patch) | |
tree | e781d3c03ca00971bd09fee593f4637a078372ac /ishtar_common/models.py | |
parent | e295d2e5e6f62a722c42d08f6156d5a785264420 (diff) | |
download | Ishtar-0020350e9b82f01a1518fd78a32ce12be018a216.tar.bz2 Ishtar-0020350e9b82f01a1518fd78a32ce12be018a216.zip |
✨ document type: add order
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r-- | ishtar_common/models.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index a5fcc1a91..8ffc2ff2f 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -4586,7 +4586,7 @@ def author_post_save(sender, **kwargs): post_save.connect(author_post_save, sender=Author) -class SourceType(HierarchicalType): +class SourceType(OrderedHierarchicalType): coins_type = models.CharField( _("COInS export - type"), default="document", max_length=100 ) @@ -4603,7 +4603,7 @@ class SourceType(HierarchicalType): class Meta: verbose_name = _("Document type") verbose_name_plural = _("Document types") - ordering = ["label"] + ordering = ("parent__order", "parent__label", "order", "label",) ADMIN_SECTION = _("Documents") |