Part 4 - Creating the second component of the product manager dashboard

Overview

To complete the product manager dashboard, we'll make it so that the admin can filter the results based on UserDate and Status.

 

Source code

The following source code is shared using Confluence Storage Format - the XHTML-based format that Confluence uses to store the content of pages, page templates, blueprints, blog posts and comments.

For more information on how to use this source code on your Confluence, read the following article - How do I use Recipes that use the Storage Format with the Confluence Source Editor?

<ac:structured-macro ac:macro-id="66ffc2d2-2b30-481a-b205-bbfa5cc3f886" ac:name="show-if" ac:schema-version="1"> <ac:parameter ac:name="user"> <ri:user ri:userkey="2c9180826b456b39016b456c262a0000"/> </ac:parameter> <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="6116a97d-98da-4b9b-a599-3769114684bd" ac:name="deck" ac:schema-version="1"> <ac:parameter ac:name="id">Admin View </ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="90d6f8bd-773e-48ef-897b-c96120d7c446" ac:name="card" ac:schema-version="1"> <ac:parameter ac:name="label">Filter By User</ac:parameter> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 26.3967%;"> <colgroup> <col style="width: 19.5286%;"/> <col style="width: 80.1347%;"/> </colgroup> <tbody> <tr> <th>Select User</th> <td> <div class="content-wrapper"> <ac:structured-macro ac:macro-id="c2c5d941-92eb-498a-a21b-d20514199b8b" ac:name="list-data" ac:schema-version="1"> <ac:parameter ac:name="name">userSearch</ac:parameter> <ac:parameter ac:name="type">auto complete</ac:parameter> <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="2822037c-00b5-4f3e-a0e5-ed2e5bf0ea6a" ac:name="user-options" ac:schema-version="1"> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> </div> </td> </tr> </tbody> </table> <ac:structured-macro ac:macro-id="38d5eb12-68b2-4ab9-adba-e318f017cadb" ac:name="report-table" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="cdf98a74-8378-4150-8723-ebacae1f3445" ac:name="expanding-reporter" ac:schema-version="1"> <ac:parameter ac:name="as">Task</ac:parameter> <ac:parameter ac:name="">data:Task</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="40c9aada-a259-4751-903d-8e02c1a875c9" ac:name="local-reporter" ac:schema-version="1"> <ac:parameter ac:name="">page:children</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <p> <ac:structured-macro ac:macro-id="36cf05ae-9455-4f72-a42b-de0f17e215e3" ac:name="text-filter" ac:schema-version="1"> <ac:parameter ac:name="value">%data:userSearch>1%</ac:parameter> <ac:parameter ac:name="">data:User</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="c4aa2d45-bc41-4bdf-9464-a59f5e2ce672" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:parameter ac:name="title">Assignee</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="b8c14c79-53e0-4525-8a91-f2b6989404ed" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:User</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="6d8d1d54-748f-4e0f-b556-979d99a15ba9" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Description</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="7d3e4e03-c535-4369-8fe8-9f4311318888" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="render">richtext</ac:parameter> <ac:parameter ac:name="">Task>data:Description</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="b6209faf-9884-43c0-b8e6-befcda7d1dc8" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Due Date</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="97bd7c3a-800c-4bd8-9c19-407e2687fd63" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="format">dd MMMM, yyyy</ac:parameter> <ac:parameter ac:name="">Task>data:Due Date</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="6fabb5cc-ddd3-4a07-8eee-704d5946065a" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Status</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="90b3c925-27ad-4bf0-8ebb-9adc07b68de6" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:Status</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="c9d1a5b4-768a-446b-9af6-4676a5fbbf52" ac:name="report-footer" ac:schema-version="1"> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 20.6701%;"> <colgroup> <col style="width: 27.5482%;"/> <col style="width: 72.4518%;"/> </colgroup> <tbody> <tr> <td class="highlight-red" colspan="2" data-highlight-colour="red" style="text-align: center;" title="Background colour : Red"> <p title="">Total Number of Tasks: </p> <div class="content-wrapper" title=""> <p> <ac:structured-macro ac:macro-id="4ca0475c-c031-462a-a1ab-a5423757c1c1" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">report:query>size</ac:parameter> </ac:structured-macro> </p> </div> </td> </tr> </tbody> </table> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> <p> <br/> </p> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="932745d7-2098-41a5-b069-16e3f7846f09" ac:name="card" ac:schema-version="1"> <ac:parameter ac:name="label">Filter By Due Date</ac:parameter> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 28.5255%;"> <colgroup> <col style="width: 18.2762%;"/> <col style="width: 81.4123%;"/> </colgroup> <tbody> <tr> <th>Select Date</th> <td> <div class="content-wrapper"> <ac:structured-macro ac:macro-id="7ff4828b-b855-41d4-bdfb-b83344a842c7" ac:name="date-data" ac:schema-version="1"> <ac:parameter ac:name="format">dd-MMM-yyyy</ac:parameter> <ac:parameter ac:name="name">dateSearch</ac:parameter> <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter> </ac:structured-macro> </div> </td> </tr> </tbody> </table> <ac:structured-macro ac:macro-id="9d6dc1af-3c46-4cc7-91fd-3cf07cbee480" ac:name="report-table" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="e25a034f-400a-4326-877b-30a526c94b9b" ac:name="expanding-reporter" ac:schema-version="1"> <ac:parameter ac:name="as">Task</ac:parameter> <ac:parameter ac:name="">data:Task</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="e59b95f0-492a-4d6a-a3b7-ebbdac3bd0ca" ac:name="local-reporter" ac:schema-version="1"> <ac:parameter ac:name="">page:children</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <p> <ac:structured-macro ac:macro-id="232bf2d1-2dc3-4f12-9ead-c77c67b93198" ac:name="number-filter" ac:schema-version="1"> <ac:parameter ac:name="aboveValue">%data:dateSearch>milliseconds%</ac:parameter> <ac:parameter ac:name="">data:Due Date>milliseconds</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="b1ceaa1b-c8f2-44e9-a7a6-7b729e35de74" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:parameter ac:name="title">Assignee</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="f8525054-5998-4377-acd1-bdd512776a3d" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:User</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="cd901fc3-200e-44b0-b93c-4a97e2acb564" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Description</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="ec152cf0-e456-46f4-9f92-5927571104be" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="render">richtext</ac:parameter> <ac:parameter ac:name="">Task>data:Description</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="6d6842de-22d9-40ba-ac84-f99d83c51d5b" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Due Date</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="74d0445f-1dad-4603-aea9-69c9d89c9a82" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="format">dd MMMM, yyyy</ac:parameter> <ac:parameter ac:name="">Task>data:Due Date</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="8be7b5f3-d115-4ed3-91ff-d36a9b7bb752" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Status</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="dbd2ea20-c19f-497b-94ef-ec64944198bc" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:Status</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="7bea169e-288f-44a3-81be-0f07e069ff90" ac:name="report-footer" ac:schema-version="1"> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 20.6701%;"> <colgroup> <col style="width: 27.5482%;"/> <col style="width: 72.4518%;"/> </colgroup> <tbody> <tr> <td class="highlight-red" colspan="2" data-highlight-colour="red" style="text-align: center;" title="Background colour : Red"> <p title="">Total Number of Tasks: </p> <div class="content-wrapper" title=""> <p> <ac:structured-macro ac:macro-id="b37aa8bf-5719-4fd8-b07a-cb9b6a38e987" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">report:query>size</ac:parameter> </ac:structured-macro> </p> </div> </td> </tr> </tbody> </table> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> <p> <br/> </p> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="5fe41a7c-bc08-4b76-bc81-67b6bf7d9567" ac:name="card" ac:schema-version="1"> <ac:parameter ac:name="label">Filter By Status</ac:parameter> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 25.971%;"> <colgroup> <col style="width: 22.5873%;"/> <col style="width: 77.3443%;"/> </colgroup> <tbody> <tr> <th>Select Status</th> <td> <div class="content-wrapper"> <ac:structured-macro ac:macro-id="6956bcb8-9967-4e44-906c-59c042f87974" ac:name="list-data" ac:schema-version="1"> <ac:parameter ac:name="name">statusSearch</ac:parameter> <ac:parameter ac:name="atlassian-macro-output-type">INLINE</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="f1956060-e6bd-4959-993f-c3122deae231" ac:name="list-option" ac:schema-version="1"> <ac:parameter ac:name="value">Open</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="f9d8f4e1-d373-4bd7-94d9-07aeb90a939f" ac:name="list-option" ac:schema-version="1"> <ac:parameter ac:name="value">In Progress</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="3347e340-dd00-4b6a-969d-a8261c73d384" ac:name="list-option" ac:schema-version="1"> <ac:parameter ac:name="value">Done</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> </div> </td> </tr> </tbody> </table> <ac:structured-macro ac:macro-id="7302f6ce-b193-4091-9349-ebbcc1391100" ac:name="report-table" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="9c746784-f82c-41c9-9c40-ca77abda98a2" ac:name="expanding-reporter" ac:schema-version="1"> <ac:parameter ac:name="as">Task</ac:parameter> <ac:parameter ac:name="">data:Task</ac:parameter> <ac:rich-text-body> <ac:structured-macro ac:macro-id="84fbdea6-927f-45a5-a16d-ea1a15599980" ac:name="local-reporter" ac:schema-version="1"> <ac:parameter ac:name="">page:children</ac:parameter> <ac:rich-text-body> <p> <br/> </p> </ac:rich-text-body> </ac:structured-macro> <p> <ac:structured-macro ac:macro-id="8928baab-faa0-48d1-91dc-107f11376696" ac:name="text-filter" ac:schema-version="1"> <ac:parameter ac:name="value">%data:statusSearch>1%</ac:parameter> <ac:parameter ac:name="">data:Status</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="218c8e0a-a4a1-433a-aa9f-5eb3e32ef7b4" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="injected">true</ac:parameter> <ac:parameter ac:name="title">Assignee</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="8720d5ed-58df-489b-9926-06c0c6e15cc6" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:User</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="6c5b0d65-2592-4f49-8c1b-96e80b9c6c70" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Description</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="3b19141c-3b2a-4984-a453-a698644f6869" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="render">richtext</ac:parameter> <ac:parameter ac:name="">Task>data:Description</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="e978cea1-0517-4e8d-b855-7ccfa33b8a60" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Due Date</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="e05cb75c-7591-486b-b54a-d8f7e794975a" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="format">dd MMMM, yyyy</ac:parameter> <ac:parameter ac:name="">Task>data:Due Date</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="6066009f-2a29-4136-a946-c5fb66db4460" ac:name="report-column" ac:schema-version="1"> <ac:parameter ac:name="title">Status</ac:parameter> <ac:rich-text-body> <p> <ac:structured-macro ac:macro-id="e80d0543-d234-46f9-a693-7ba7072a8664" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">Task>data:Status</ac:parameter> </ac:structured-macro> </p> </ac:rich-text-body> </ac:structured-macro> <ac:structured-macro ac:macro-id="7359abff-9584-4cbf-be6a-45c698b90497" ac:name="report-footer" ac:schema-version="1"> <ac:rich-text-body> <table class="wrapped relative-table" style="width: 20.6701%;"> <colgroup> <col style="width: 27.5482%;"/> <col style="width: 72.4518%;"/> </colgroup> <tbody> <tr> <td class="highlight-red" colspan="2" data-highlight-colour="red" style="text-align: center;" title="Background colour : Red"> <p title="">Total Number of Tasks: </p> <div class="content-wrapper" title=""> <p> <ac:structured-macro ac:macro-id="6383b625-e2cc-4e3a-8621-5217fa075ace" ac:name="report-info" ac:schema-version="1"> <ac:parameter ac:name="">report:query>size</ac:parameter> </ac:structured-macro> </p> </div> </td> </tr> </tbody> </table> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro> </ac:rich-text-body> </ac:structured-macro>

Steps

On a draft page

  • add three level 3 headings (H3)

    • "Filter By User"

    • "Filter By Due Date"

    • "Filter By Status"


Create “Filter by User” results

Under the "Filter By User" heading

  • add a 2x1 table

    • enter "Select User" in the first column

    • add a List Data macro in the second column

      • set name to "userSearch"

      • set type to "auto complete"

    • add a User Options macro within the List Data macro

Below the table

In this Report Table  macro

  • create an Expanding Reporter

    • set its Key parameter to "data:Task"

    • set its As parameter to "Task" 

In the Expanding Reporter macro

Add report columns

Within the Report Table (below the Expanding Reporter macro)

  • add four Report Column macros

    • set their titles to "Assignee", "Description", "Due Date" and "Status" respectively

In the "Assignee" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:User"

In the "Description" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Description"

In the "Due DateReport Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Due Date"

In the "Status" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Status"

Within this table cell

  • write "Total Number of Tasks:"

  • add a Report Info macro

    • set its Key parameter to "Report:query>size"


Create “Filter by Due Date” results

Under the "Filter by Due Date" heading

  • add a 2x1 table

    • write "Select Date" in the first column

    • add a Date Data macro in the second column

      • set its name to "dateSearch" 

Below the table

Within the Report Table macro

  • create an Expanding Reporter macro

    • set its Key parameter to "data:Task"

    • set its As parameter to "Task"

In the Expanding Reporter macro

  • create a Local Reporter macro

    • set its Key parameter to "page:children"

  • add a Number Filter macro (in the Expanding Reporter macro)

    • set its Key parameter to "data:Due Date>milliseconds"

    • set its Above Value parameter to "%data:dateSearch>milliseconds%" 

Add report columns

Within the Report Table macro (below the Expanding Reporter macro)

  • add four Report Column macro

    • set their title to "Assignee", "Description", "Due Date" and "Status" respectively

In the "Assignee" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:User"

In the "Description" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Description"

In the "Due DateReport Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Due Date"

In the "Status" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Status"

Within this table cell

  • type  "Total Number of Tasks:"

  • add a Report Info macro

    • set its Key parameter to "Report:query>size"


Create “Filter by Status” results

Under the "Filter By Status"  heading

  • add a 2x1 Table

    • write "Select Status" in the first column

    • add a List Data macro in the second column

      • set its name to "statusSearch" 

Within the List Data macro

  • add 3 List Option macros

    • set their Value parameters to "Open", "In Progress", and "Done" respectively

Below the table

Within this Report Table macro

  • create an Expanding Reporter macro

    • set its Key parameter to "data:Task"

    • set its As parameter to "Task"

Within the Expanding Reporter macro

  • create a Local Reporter macro

    • set its Key parameter to "page:children"

  • add a Text Filter macro (within the Expanding Reporter macro)

    • set its Key parameter to "data:Status"

    • set Exact Value parameter to %data:statusSearch>1%"

Add report columns

Within the Report Table macro (below the Expanding Reporter macro)

  • add four Report Column macros

    • set their title to "Assignee", "Description", "Due Date" and "Status" respectively

In the "Assignee" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:User"

In the "Description" Report Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Description"

In the "Due DateReport Column macro

  • add a Report Info macro

    • set its Key parameter to "Task>data:Due Date"

In the "Status" Report Column macro

  • add a Report Info macro

  • set its Key parameter to "Task>data:Status"

Within the Report Footer macro table cell

  • write "Total Number of Tasks:"

  • add a Report Info macro

    • set its Key parameter to "Report:query>size"


Macro structure