Changes for page Rangee Index
Last modified by Tobias Wintrich on 2025/06/04 09:20
From version 12.23
edited by Tobias Wintrich
on 2021/09/28 11:55
on 2021/09/28 11:55
Change comment:
There is no comment for this version
To version 12.31
edited by Tobias Wintrich
on 2021/09/28 12:01
on 2021/09/28 12:01
Change comment:
There is no comment for this version
Summary
-
Objects (1 modified, 0 added, 0 removed)
Details
- XWiki.WikiMacroClass[0]
-
- Macro code
-
... ... @@ -1,8 +1,13 @@ 1 1 {{velocity}} 2 -{{tree links="true" edges="false"}} 2 +##{{tree links="true" edges="false"}} 3 3 #set($depth = $wikimacro.parameters.depth) 4 +#if ($xcontext.locale == 'de') 5 + #set($locale = '') 6 +#else 7 + #set($locale = $xcontext.locale) 8 +#end 4 4 {{html wiki=true}} 5 - $doc.getLanguage()10 +language $locale 6 6 <ul> 7 7 #set($results = false) 8 8 #set ($query = $services.query.xwql('where doc.parent = :doc and doc.hidden = 0 order by doc.title asc')) ... ... @@ -9,13 +9,15 @@ 9 9 #set($results = $query.bindValue('doc', $doc.fullName).addFilter('currentlanguage').execute()) 10 10 #foreach($docname in $results) 11 11 #set($rdoc = $xwiki.getDocument($docname).getTranslatedDocument()) 12 - <li class="$rdoc.getLanguage() 13 - #if ($depth > 0) 14 - jstree-open 17 + #if ($locale == $rdoc.getLanguage()) 18 + <li class=" 19 + #if ($depth > 0) 20 + jstree-open 21 + #end 22 + "> 23 + [[$rdoc.getDisplayTitle()>>$rdoc.fullName]] 24 + </li> 15 15 #end 16 - "> 17 - [[$rdoc.getDisplayTitle()>>$rdoc.fullName]] 18 - </li> 19 19 #set($results2 = false) 20 20 #set($query2 = $services.query.xwql('where doc.parent=:doc and doc.hidden = 0 order by doc.title asc')) 21 21 #set($results2 = $query2.bindValue('doc', $docname).addFilter('currentlanguage').execute()) ... ... @@ -80,5 +80,5 @@ 80 80 </ul> 81 81 82 82 {{/html}} 83 -{{/tree}} 90 +##{{/tree}} 84 84 {{/velocity}}