Highlight Overdue Issues

Here is a relatively simple way to highlight overdue issues… the more overdue they are, the hotter the colour:

img2e.jpg

There is an overdue custom field plugin – but I didn't want to use that because I needed something without restarting jira. Also this lets you have a gradient for overdue issues, and have different gradients and colours in different contexts (dashboards).

The downside is that this only works on dashboards, and only if you are using the Show Saved Filter With Columns, or Show Saved Filter Select Columns plugin portlets. And only if your language is English and the date format is like 19/Oct/09… if not you could modify the javascript.

You must be showing the Due date column, because the javascript reads that date to work out how overdue the issue is.

Then create a new portlet of type Text. This is not enabled by default, to enable go to Plugins -> Portlets Plugin -> Text, and click Enable Module.

Download highlightOverdue.js and put in atlassian-jira/includes/js.

Now add a Text portlet to your dashboard.

It should contain:

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script> 
<script language="JavaScript" type="text/javascript" src="/includes/js/HighlightOverdue.js"></script>

No restart of jira necessary. Now if that worked, sit back and enjoy glorious technicolor filter results.

3 comments to Highlight Overdue Issues

  • Nice. I didn’t know you could add javascript files dynamically like that. What happens if you change the file – how do you force a reload?

    ~Matt

  • 4.2 doesn’t seem to like adding a text portlet, and adding the initial script element to the Introduction doesn’t seem to work either. I guess I could add a new gadget, or do a speakeasy client-side thing or a full-blown plugin to modify the behaviour.

    ~Matt

  • Yeah… I can see how the asynchronous nature of the gadgets in 4.2 could cause problems. You’d need to get a handle to the filter gadget and somehow get notified of when it had finished loading.

Leave a Reply