0 Votes

Changes for page AWMKanbanMacro

Last modified by Ryan C on 2025/07/17 22:45

From version 5.1
edited by Ryan C
on 2025/06/04 14:23
Change comment: Install extension [org.xwiki.contrib:macro-kanban/1.4.0]
To version 6.1
edited by Ryan C
on 2025/07/17 22:45
Change comment: Install extension [org.xwiki.contrib:macro-kanban/1.4.1]

Summary

Details

Page properties
Content
... ... @@ -12,6 +12,8 @@
12 12  * ##xwql## - additional xwql to restrict the query
13 13  * ##title## - field to display the title
14 14  * ##columns## - the class fields to display as a description in each card
15 +* ##order## - order to sort the data by. Example: 'doc.name desc', 'doc.date desc', 'customClassField1 asc, customClassField2 desc, doc.name desc' or 'customClassField1 asc' if the className object contains such custom fields
16 +* ##limit## - the maximum amount of items to show. If the ##displayedCategoryColumns## parameter is set, the limit is applied for each column.
15 15  
16 16  Examples:
17 17  
XWiki.WikiMacroClass[1]
Macro code
... ... @@ -34,10 +34,12 @@
34 34   #set($colors = "#8C4,#0AC,#F91,#FC3,#E43")
35 35  #end
36 36  #set ($displayedCategoryColumns = "$!xcontext.macro.params.displayedCategoryColumns")
37 +#set ($order = "$!xcontext.macro.params.order")
38 +#set ($limit = "$!xcontext.macro.params.limit")
37 37  
38 38  #set($width = "$xcontext.macro.params.width")
39 -#set($source = $xwiki.getDocument("Macros.KanbanAWMSource").getURL("get", "xpage=plain&outputSyntax=plain&className=${escapetool.url($className)}&category=${escapetool.url($category)}&displayedCategoryColumns=${escapetool.url($displayedCategoryColumns)}&title=${escapetool.url($title)}&columns=${escapetool.url($columns)}&xwql=${escapetool.url($xwql)}&colors=${escapetool.url($colors)}"))
41 +#set($source = $xwiki.getDocument("Macros.KanbanAWMSource").getURL("get", "xpage=plain&outputSyntax=plain&className=${escapetool.url($className)}&category=${escapetool.url($category)}&displayedCategoryColumns=${escapetool.url($displayedCategoryColumns)}&title=${escapetool.url($title)}&columns=${escapetool.url($columns)}&xwql=${escapetool.url($xwql)}&colors=${escapetool.url($colors)}&order=${escapetool.url($order)}&limit=${escapetool.url($limit)}"))
40 40  #set($awmupdatepath = "/objects/${className}/0/properties/${category}/")
41 -{{kanban source="${source}" updateService="" addBoardButton="false" addItemButton="false" removeBoardButton="false" removeItemButton="false" awmupdatepath="${awmupdatepath}" width="${width}" /}}
43 +{{kanban source="${source}" updateService="" addBoardButton="false" addItemButton="false" removeBoardButton="false" addRemoveButton="false" awmupdatepath="${awmupdatepath}" width="${width}" /}}
42 42  {{/velocity}}
43 43  
XWiki.WikiMacroParameterClass[6]
Parameter description
... ... @@ -1,1 +1,1 @@
1 -Order to sort the data by
1 +Order to sort the data by. Example: 'doc.name desc', 'doc.date desc', or 'customClassField1 asc' if the className object contains such a field. Sort by multiple fields: 'customClassField1 asc, customClassField2 desc, doc.name desc'
XWiki.WikiMacroParameterClass[13]
Parameter default value
... ... @@ -1,0 +1,1 @@
1 +50
Parameter name
... ... @@ -1,0 +1,1 @@
1 +limit
Parameter description
... ... @@ -1,0 +1,1 @@
1 +Set the maximum amount of items to show. If the displayedCategoryColumns parameter is set, the limit is applied for each column.
Parameter mandatory
... ... @@ -1,0 +1,1 @@
1 +No

XWiki AI Chat