Commit e5792f39 authored by Julien Muchembled's avatar Julien Muchembled

simulation: on SM/AR views, only sort by base categories

For some base categories like specialise, the order of categories is important.
list.sort implements a stable sort so we can use it here.
parent 1d4a9b67
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>categories_list = context.getCategoriesList()\n <value> <string>categories_list = context.getCategoriesList()\n
categories_list.sort()\n categories_list.sort(key=lambda x: x.split("/", 1)[0])\n
return categories_list\n return categories_list\n
</string> </value> </string> </value>
</item> </item>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment