Changes for page Space Index
Last modified by Simon Urli on 2024/04/09 11:23
Summary
-
Page properties (1 modified, 0 added, 0 removed)
-
Objects (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Author
-
... ... @@ -1,1 +1,1 @@ 1 -xwiki:XWiki. VincentMassol1 +xwiki:XWiki.mflorea
- XWiki.WikiMacroClass[0]
-
- Macro code
-
... ... @@ -13,7 +13,7 @@ 13 13 #if ("$!spaceMacroParam" != '') 14 14 #set ($spaceParam = $spaceMacroParam) 15 15 #end 16 - #set ($docNames = $ser vices.query.hql('where doc.space=? order by doc.creationDate desc').setLimit($limit).bindValues([${spaceParam}]).execute())16 + #set ($docNames = $xwiki.searchDocuments('where doc.space=? order by doc.creationDate desc', $limit, 0, [${spaceParam}])) 17 17 {{html}} 18 18 #displayDocumentList($docNames false []) 19 19 ## Note: we pass an empty blacklistedSpaces list since we are used as a space dashboard, not a global dashboard ... ... @@ -20,7 +20,7 @@ 20 20 {{/html}} 21 21 22 22 #if ($docNames.size() == $limit) 23 - #set ($docCount = $ services.query.xwql('where doc.space:space').bindValue('space', $spaceParam).addFilter('unique').count())23 + #set ($docCount = $xwiki.countDocuments('where doc.space=?', [${spaceParam}])) 24 24 #set ($remaining = $mathtool.sub($docCount, $limit)) 25 25 #if ($remaining > 0) 26 26 (% class="documentListMore" %) (((