We're starting to use Atlassians "page properties" & "Page Properties Report" macros in our organisation and my user community is aksing whether it's possible to add a count / totals the results of the "page properties report" display/output (currently it lists all pages but you have to manually count how many results it returns).
Currently, I can see that adding totals is *not* an option within the macro editor, however I'm not sure if there's a change/feature request out there? Does anyone know whether there are alternative methods I can use to generate totals for the "Page Properties Report"? I wondered whether there's any macros/plugins that allow pages counts by page label (i.e. I caould insert the same page label used in the page properties macro).
Any insight/advice welcomed.
Here is a user macro to count pages by label.
## @param Label:title=Label|type=string|required=true|desc=Enter a label to count.
#set( $labelManager = $action.LabelManager )
#set( $labRef = $labelManager.getLabel($paramLabel) )
#set( $pages = $labelManager.getCurrentContentForLabel( $labRef) )
How can I count pages with a specific page property?
E.g. in this tutorial (https://confluence.atlassian.com/display/DOC/Page+Properties+Macro) the total amount of pages with Current Status "In progress"?
Thanks for any advice/help.
the macro works fine if I use it only one time on a page. But I get an error when used multiple time on the same page.
I work on Confluence 5.4.1
Any ideas? Thank you in advance!
java.lang.RuntimeException: Error rendering template for decorator root
caused by: java.lang.RuntimeException: Error rendering template for decorator page
caused by: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getWebInterfaceContext' in class com.atlassian.confluence.pages.actions.ViewPageAction threw exception net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection at template/includes/menu-macros.vm[line 123, column 92]
caused by: net.sf.hibernate.LazyInitializationException: Failed to lazily initialize a collection
caused by: net.sf.hibernate.HibernateException: collection was evicted
Hi my Community friends! For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs