Changes for page Documents Macro
Last modified by Ludovic Dubost on 2024/07/22 15:50
From version 5.1
edited by Ludovic Dubost
on 2016/04/01 11:48
on 2016/04/01 11:48
Change comment:
Install extension [org.xwiki.platform:xwiki-platform-index-ui-8.0]
To version 7.1
edited by Ludovic Dubost
on 2018/07/01 11:40
on 2018/07/01 11:40
Change comment:
Install extension [org.xwiki.platform:xwiki-platform-index-ui/10.5]
Summary
-
Page properties (1 modified, 0 added, 0 removed)
-
Objects (1 modified, 1 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -4,4 +4,4 @@ 4 4 5 5 Generates: 6 6 7 -{{documents id="example" count="5" actions="false" space="Main" parent="Main.WebHome" columns="doc.title, doc.location"/}}7 +{{documents id="example" count="5" actions="false" columns="doc.title, doc.location"/}}
- XWiki.WikiMacroClass[0]
-
- Macro code
-
... ... @@ -8,13 +8,12 @@ 8 8 #set($collist = ['doc.title', 'doc.location', 'doc.date', 'doc.author']) 9 9 #end 10 10 #set($colprops = { 11 - 'doc.title' : { 'type' : 'text' , 'size' : 30, 'link' : 'view', 'filterable': false, 'sortable': false }, 12 - 'doc.location' : { 'type': 'text', 'filterable': true, 'html': true}, 13 - 'doc.fullName' : { 'type' : 'text' , 'size' : 30, 'link' : 'view' }, 14 - 'doc.name' : { 'type' : 'text' , 'size' : 30, 'link' : 'view' }, 15 - 'doc.space' : { 'type' : 'text', 'link' : 'space' }, 16 - 'doc.date' : { 'type' : 'date' }, 17 - 'doc.author' : { 'type' : 'text', 'link' : 'author' } 11 + 'doc.title' : { 'size' : 30, 'link' : 'view', 'filterable': false, 'sortable': false }, 12 + 'doc.location' : { 'html': true }, 13 + 'doc.fullName' : { 'size' : 30, 'link' : 'view' }, 14 + 'doc.name' : { 'size' : 30, 'link' : 'view' }, 15 + 'doc.space' : { 'link' : 'space' }, 16 + 'doc.author' : { 'link' : 'author' } 18 18 }) 19 19 #set($options = { 20 20 'translationPrefix' : 'platform.index.', ... ... @@ -24,6 +24,9 @@ 24 24 #if ("$!xcontext.macro.params.space" != "") 25 25 #set ($extraParams = "&space=$escapetool.url($xcontext.macro.params.space)") 26 26 #end 26 +#if ("$!xcontext.macro.params.location" != "") 27 + #set ($extraParams = "$!{extraParams}&location=$escapetool.url($xcontext.macro.params.location)") 28 +#end 27 27 #if ("$!xcontext.macro.params.parent" != "") 28 28 #set ($extraParams = "$!{extraParams}&parent=$escapetool.url($xcontext.macro.params.parent)") 29 29 #end ... ... @@ -32,7 +32,11 @@ 32 32 #end 33 33 #if(!$isGuest && $xcontext.macro.params.actions == "true") 34 34 #set($discard = $collist.add('_actions')) 35 - #set($discard = $colprops.put('_actions', { 'actions' : ['copy', 'rename', 'rights', 'delete'] })) 37 + #set($discard = $colprops.put('_actions', { 38 + 'actions': ['copy', 'rename', 'rights', 'delete'], 39 + 'filterable': false, 40 + 'sortable': false 41 + })) 36 36 #end 37 37 #if ("$!xcontext.macro.params.id" != "") 38 38 #set ($livetableId = $xcontext.macro.params.id)
- XWiki.WikiMacroParameterClass[6]
-
- Parameter description
-
... ... @@ -1,0 +1,1 @@ 1 +Only lists documents having a full reference matching the passed location (e.g. passing "Beau" would match a document reference of "France.Paris.Beaubourg.Office") - Parameter mandatory
-
... ... @@ -1,0 +1,1 @@ 1 +No - Parameter name
-
... ... @@ -1,0 +1,1 @@ 1 +location