Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How to show the task of a login user in a dashboard / solved

Henricus Fluthgraf May 8, 2018

I have a dashboard space 

the login user don‘t have a personal space.

how can I show them their task?

i didn‘t find a original tool in the atlassian area.

i only heared, I need to write a macro.

i am not a software programmer, so who can help me?

 

best Henry 

3 answers

1 accepted

6 votes
Answer accepted
Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 10, 2018

Since you are on Confluence Server you can use a user macro to wrap the task report macro to supply the current user. The way you can do this would be to create a task report macro with all the parameters set up the way you want. Make sure to set yourself as the user (we will override this in a bit). You will need the Confluence Source Editor for this next part. It's an add-on made by Atlassian. This will give you the option to look at the storage format for your page which is a a semi-html looking format. Look for the xml for your macro setup. It should look something like this ...

<ac:structured-macro ac:macro-id="{some numbers and letters}" ac:name="tasks-report-macro" ac:schema-version="1">
<ac:parameter ac:name="assignees">
<ri:user ri:userkey="{some numbers and letters}"/>
</ac:parameter>
</ac:structured-macro>

I accepted the defaults for most of the parameters so my example above only shows the assigness parameter. Yours may show more if you change some of the parameters from the default. But this will get us the storage format we will need to create a user macro. From here we can create a user macro where we will use all the settings you set but override the assignees section.

So, go create a new user macro with these settings ...

Macro Name:
current_user_task_report

Macro Title:
Current User Task Report

Description:
Create a report of tasks for the current user from specific locations, people, status and more.

Macro Body Processing:
No macro body

Template:

## @noparams
<ac:structured-macro ac:name="tasks-report-macro" ac:schema-version="1">
 <ac:parameter ac:name="assignees">
  <ri:user ri:userkey="$action.remoteUser.key"/>
 </ac:parameter>
</ac:structured-macro>

 

So the Template above will basically just be what you grabbed from the source editor but you will change the ...

<ri:user ri:userkey="{some numbers and letter}"/>

to 

<ri:user ri:userkey="$action.remoteUser.key"/>

Then save your user macro and use it wherever you want a task report that shows only the current user's tasks.

AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 10, 2018

Thank you for this superlative post @Davin Studer!

Like Matthew Davison likes this
Henricus Fluthgraf May 10, 2018

Hello @Davin Studer,

thx. This it is. It works. 1000 thx for your detailed Explanation.

Best Henry

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 11, 2018

No problem. Please make sure to mark the question as answered. Thanks.

Henricus Fluthgraf May 11, 2018

I did it in the headlin, or is there any other possibility ?

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 11, 2018

There is a checkmark next to answers. Checking that mark it as the answer to the question.

Capture.PNG

Henricus Fluthgraf May 11, 2018

thx, so i marked it as solved ;-) again 1000 thx

Marek Wowkostryl April 30, 2019

Hello Davin!

Your solution is great, although I've encountered that your macro shows only tasks where there is only one assignee or  user is first of all assignees in the task.

So, in other words, when in the task there are few assignees, the task is shown in the list only, when logged user is first of assignees.

I hope I made it clear. :)

Can you help with such issue?

Stian Espe May 23, 2019

Hi! Trying to get your brilliant tip to work, however i only get the following output when following your guide, any idea? 
- I do have task assigned to myself
- After changing the source to the below, the task report is empty.

<ri:user ri:userkey="$action.remoteUser.key"/>

Task report.png

Davin Studer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 23, 2019

You can't do it by changing the source. You need to create a user macro. The source editor is simple to set the macro up the way you want initially and then to get the storage format for that setup. The user macro will then do the work of dynamically swapping out the user piece for you. By changing the source you are telling the macro to literally show tasks for the user "$action.remoteUser.key" ... which of course that user doesn't really exist.

Like Stian Espe likes this
Stian Espe June 23, 2019

Sorry about that, should have read more carefully thru your description.. 
Tested & Works.. =) Thanks!

Joyner Stance March 7, 2021

Hello, 

I managed to create the user macro, even though it requires you to set some parameters otherwise it won't be displayed in the macro list. 

Still, I would like to extend this to be able to also select tasks:

  • with no due date
  • with no assignee

Anybody has an idea how?

I'm reading up on Velocity as we speak, but I hope I can also find some quick help around here. 

0 votes
Sam Yil July 31, 2023

Hi @Davin Studer

is there a workaround or another approach for DataCenter? We use Confluence DataCenter (7.19.9) and this unfortunately does not work for us. I don't get any result(enough tasks are available, different & same space, page..). Configured as you specified..

2023-07-31 17_18_24-Window.jpg

Thanks in advance!

Sam

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 8, 2018

Hi Henricus,

We do have the task report macro in Confluence. Use the Task Report macro to display a list of tasks on a page. Filter the tasks by space, page, user, label, created date and more.

Please let me know if that works for your case.

Thanks,

Ann

Fluthgraf May 8, 2018

@AnnWorley

yes, i know, but set a filter for a user (static) but the filter should be dynamic. Only Show the Task for the logged in user.

@mr.x :  is spec

it should be something like

@loggedinuser (how to set)

what can i write into the field user to make the setting depending on the logged in user.

 

Best Henry

Like Tristan Douville likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events