Hi there!
I am looking for a solution to list all labels of a space as in the list-label macro. However, as there are hundreds of document numbers in our spaces, I would like to ignore all labels that start with a number.
Maybe there is an easy way of writing a short user macro. Anyone?
Max
Yes, you can! It will be some work, but you can walk through pages to get a list of labels. Take a look at this macro for some guidance:
https://github.com/unidwell/confluence-include-child-pages-macro
Maybe the getLabels() method works for retrieving all the labels in space?
OR, you may be able to render the label-list macro within a user macro, and RegEx filter the list from there.
Hi @Max E
I am not really a developer so i can't solve this without some help of someone that knows javascript.
If you or someone on your team has this knowledge you should be able to write a small javascript file that uses regex to do a check on all the labels and remove or hide them if necessary.
This will work perfectly in a user macro.
Regards
Dave
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.