Time in Status gadget can be used on Confluence pages to display Time in Status reports.


Registering Time in Status Gadget in Confluence

To use Time in Status gadget on a Confluence page, first, your Jira and Confluence instance must be linked via Application Links.

Then You must register the Time in Status gadget as an external gadget to Confluence. For this...

Get the gadget XML from Jira.

  1. Open any Jira dashboard.
  2. Click on the Add Gadget button and open the Add Gadget dialog.
  3. Find Time in Status Reports gadget in the list.
  4. Click the Show XML Link link
  5. Copy the URL shown in the textbox.

Add the gadget as an external gadget to Confluence

  1. Open the External Gadgets admin page of Confluence.
  2. Paste the gadget XML URL you obtained in the first stage to the Gadget Specification URL textbox and click Add.
  3. The XML entry should appear in the Added Gadgets list below.


Adding Time in Status Gadget to a Confluence Page

  1. While the Confluence page is in Edit mode, open the Macro Browser
  2. Search for Time in Status Reports macro.
  3. Click on the macro.
  4. This should take you directly to the Edit Macro dialog.


Configuring the Gadget

To configure an existing Time in Status gadget on a Confluence page...

  1. Put the Confluence page in Edit mode.
  2. Click on the Time in Status Reports macro and click Edit.
  3. The Edit Macro dialog box will show the gadget in view mode by default. Scroll down and select the Edit option in the settings menu to open the gadget's config dialog.
  4. Configure the gadget as explained in the Gadget page.
  5. (Optional) Set the width property according to your needs or set it to 100% to make the gadget use the whole page width.
  6. Save the gadget configuration.
    1. The Gadget's Save Button and the Edit Macro Dialog's Save Button are two separate buttons. You need to click on the gadget's save button first and then the edit macro dialog's save button to save your changes.
  7. Finally, Save the Confluence page.



When the Edit Macro dialog is opened for the first time, a login confirmation might be required.

If you see this dialog, click the Login and Approve button, follow the on-screen instruction, and then Refresh the macro (by clicking the refresh button next to Preview).


The Time in Status Gadget can be displayed on Confluence pages but PDF & Word Export options are not supported.

Some gadget icons might be missing if you are using Jira 7.13 or earlier. This is caused by a security settings of Jira that does not allow Confluence to get the icons.

You need to make a CorsFilter configuration on Jira

  • Shut down Jira
  • Edit the <jira-install-dir>/atlassian-jira/WEB-INF/web.xml file
  • Add following filter on the top of the filters.
<filter>
      <filter-name>CorsFilter</filter-name>
      <filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
      <init-param>
      <param-name>cors.allowed.origins</param-name>
      <param-value>http://confluence.domain</param-value>
      </init-param>
      <init-param>
      <param-name>cors.allowed.methods</param-name>
      <param-value>GET,POST,PUT,DELETE</param-value>
      </init-param>
      <init-param>
      <param-name>cors.exposed.headers</param-name>
      <param-value>Access-Control-Allow-Origin,Access-Control-Allow-Credentials</param-value>
      </init-param>
      <init-param>
      <param-name>cors.support.credentials</param-name>
      <param-value>true</param-value>
      </init-param>
      <init-param>
      <param-name>cors.preflight.maxage</param-name>
      <param-value>1800</param-value>
      </init-param>
</filter>


Replace http://confluence.domain on the above filter with the URL that's originating these requests. If you have more than one origin that need to access Jira resources, you can add multiple domains to the cors.allowed.origins parameter, using a comma to separate them.
  • Add following filter mapping on the top of the filter mappings.
<filter-mapping>
      <filter-name>CorsFilter</filter-name>
      <url-pattern>/*</url-pattern>
</filter-mapping>
  • Start Jira


Refer to the following Atlassian documentation page for details:

https://confluence.atlassian.com/confkb/getting-cors-errors-when-accessing-confluence-resources-1005806356.html


  • No labels