There are 3 comments.
 
 
XWiki Platform / cid:jira-generated-image-avatar-86099602-5d3d-47a1-9381-6819c6ccf5a0 XWIKI-20437 Open

Wrong order of categories in space administration

 
View issue   ยท   Add comment
 

3 comments

 
cid:jira-generated-image-avatar-a395a5e0-46e0-482d-862c-8fb8c84caf68 Charpentier Lucas on 03/Nov/25 16:25
 

The Look and Feel category is supposed to be displayed before the category `content`. My guess is that when there's every single category, the `content` category is placed relative to the L&F category. When we're administrating a page, there is no entry in the look and feel category. Therefore, it's removed from the adminmenu and its 'displayBeforeCategory' is ignored. Therefore the `content` category is displayed in the order it comes in the tree by default, which happens to be AFTER the `other` category which is already in the tree by default.

The problem is with the fact that empty category are completely skipped AND they contain information to reorder the tree.

IMO this `displayBeforeCategory` category organization variable looks quite awful. If we did it today we probably would have used an order number for those.

 
cid:jira-generated-image-avatar-a395a5e0-46e0-482d-862c-8fb8c84caf68 Charpentier Lucas on 03/Nov/25 16:25
 
The Look and Feel category is supposed to be displayed before the category `content`. My guess is that when there's every single category, the `content` category is placed relative to the L&F category. When we're administrating a page, there is no entry in the look and feel category. Therefore, it's removed from the adminmenu and its 'displayBeforeCategory' is ignored. Therefore the `content` category is displayed in the order it comes in the tree by default, which happens to be AFTER the `other` category which is already in the tree by default.

The problem is with the fact that empty category are completely skipped AND they contain information to reorder the tree.

IMO this `displayBeforeCategory` category organization variable looks quite awful. If we did it today we probably would have used an order number for those
just like it's done for the sections . ..
 
cid:jira-generated-image-avatar-a395a5e0-46e0-482d-862c-8fb8c84caf68 Charpentier Lucas on 03/Nov/25 16:33
 

In a word, we order categories in a linkedList. This data structure does not handle well being filtered :/