Restrict list of content created by a user to content-type page

I'd like to give each of our users to give a list of the pages created - only the pages, not comments, attachments etc.
User macro for the display of all content works, but how restrict it to content-type page?

 

## Macro title: Content by current user
## Body Processing: Escaped

<ac:structured-macro ac:name="content-by-user">
<ac:parameter ac:name="">
<ri:user ri:userkey="${action.authenticatedUser.key}"/>
</ac:parameter>
</ac:structured-macro>

2 answers

1 accepted

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

This should work:

## Macro title: Pages by current user
## Body Processing: Escaped
&lt;ac:structured-macro ac:name="content-by-user"&gt;
  &lt;ac:parameter ac:name=""&gt;
    &lt;ri:user ri:userkey="${action.authenticatedUser.key}"/&gt;
  &lt;/ac:parameter&gt;
&lt;/ac:structured-macro&gt;
&lt;script&gt;
  AJS.toInit(function() {
    jQuery(".grid").find("span.icon:not([title*='age'])").parent().hide();
  });
&lt;/script&gt;

There will be a few empty spaces, but that can't be helped; since Confluence doesn't support filtering by type, you have to use some javascript magic to filter the results to show only pages.

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

Hi Anne, sorry I saw your question earlier, but didn't get a chance to respond. Give me a little bit of time an I'll update the macro.

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

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