How to save labels dynamically via page properties or Labels macro?

I'm using product requirements blueprint and I need that during creation new requirement an addition label will be saved together with by default label "requirements".

The additional label should be like "xx123-requirements" where thexx123 is projectCode for example.

I need it because I want to list the requirements using Product requirements index blueprint and by filtering them with the project based label on appropriate project page.

Perfect would be use a variable like $projectCode in the page template were the "Create new requirement" macro will be placed so that the label will be concatenated by the variable $projectCode and static string "requirements".

How to do it?

P.S. Maybe there is another solution how to filter or limit the requirements list in case I put it into every project page template?

Using Confluence 5.7.

1 answer

1 accepted

3 votes
Accepted answer


Maybe another solution will be suitable for you. I don't know the whole case, but you can try to use Page Properties macro + Page Properties Report macro. Page Properties Report allows you to build the report table (you need to use labels to identify what pages should be included into the report, this can be one label like "requirements" for all requirements pages). Then your report table can be easily filtered with Table Filter and Charts add-on.

As a result, you'll get something like this:

image2016-8-5 16:18:35.png 

Is it not possible to define a variable within the page that then sets the value for the macro on the page? Trying to create global templates with Macros seems impossible without this.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

816 views 40 5
Join discussion

Atlassian User Groups

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!

Find my local user group

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

Groups near you