src/pyams_thesaurus/thesaurus.py
changeset 87 dfe19304d980
parent 76 1d0d13ab5665
child 108 06272e2e8bb5
--- a/src/pyams_thesaurus/thesaurus.py	Tue Aug 28 17:02:29 2018 +0200
+++ b/src/pyams_thesaurus/thesaurus.py	Wed Aug 29 13:56:54 2018 +0200
@@ -281,7 +281,7 @@
     """Thesaurus tree adapter"""
 
     def get_root_nodes(self):
-        return self.context.top_terms
+        return sorted(self.context.top_terms, key=lambda x: (x.order or 999, x.label))
 
 
 #