Is there any equivalent variable of @self(The current space) for the page.

I want to be able to use the content by label macro specifiy that the ancestor id as the page itself.

I can manually do this per macro by typing in the name of the page but I want to put the macro in a template and not have to edit the field each time. I know @self is reserved for the space a page exists within but is there an equivalent variable for the a page?

4 answers

This widget could not be displayed.

Not yet, please vote for this issue:

This widget could not be displayed.
Stephen Deutsch Community Champion Sep 23, 2015

It doesn't seem like this is possible (there's no reference to the current page in CQL), but if you don't type but instead click in the field for ancestors, doesn't the page you are editing pop up as the first option?

This widget could not be displayed.

Managed to do with the following user macro:

## Body Processing: No macro body
## @param CQL:title=CQL|type=string|required=false|desc=CQL to filter children with
## @param firstcolumn:title=firstcolumn|type=string|required=false|desc=Title of first column
## @param headings:title=headings|type=string|required=false|desc=Columns to display


<ac:structured-macro ac:name="detailssummary" ac:schema-version="2">
    <ac:parameter ac:name="sortBy">title</ac:parameter>
    <ac:parameter ac:name="cql">$paramCQL and ancestor = "$content.getIdAsString()"</ac:parameter>
    <ac:parameter ac:name="firstcolumn">$paramfirstcolumn</ac:parameter>
    <ac:parameter ac:name="headings">$paramheadings</ac:parameter>

(Thanks to James Garratt -

This widget could not be displayed.

This doesn't help people who are using the Cloud version and can't create custom macros.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

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...

506 views 7 6
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