It would be nice to have a block with recently added/modified issues.
Like recent forum topics, but then for issues.

Ewout

CommentFileSizeAuthor
#6 project_issue-recent-issues2.patch4.91 KBmfb

Comments

pfaocle’s picture

Here, have a quick custom block:

<?php
	// Displays the ten most recently changed critical issues
	$sql = "SELECT n.nid, n.title FROM node n INNER JOIN project_issues pi ON pi.nid=n.nid INNER JOIN project_issue_state pis ON pi.sid=pis.sid";
	$sql .= " WHERE pi.priority=1 AND pis.name IN ('active', 'needs work', 'testers needed') ORDER BY n.changed DESC LIMIT 10";
	$result = db_query(db_rewrite_sql($sql));
	while ($issue = db_fetch_object($result)) {
		$items[] = l( $issue->title, 'node/'.$issue->nid);
	}
	return theme('item_list', $items);
?>

Any thoughts on having a similar, configurable block in the module itself? It could be a nice little feature,

aclight’s picture

Project: Project » Project issue tracking
Version: x.y.z » 5.x-2.x-dev
Status: Active » Postponed

Once #76725: Refactor project issue module to use Views gets finished, this shouldn't be difficult to do at all, and could be provided as a default block view in the project issue tracking module. I'm moving this into the right queue and marking as postponed.

dww’s picture

Version: 5.x-2.x-dev » 6.x-1.x-dev
Component: User interface » Views integration
Status: Postponed » Active

Indeed, this would be a trivial view.

dww’s picture

Oh, and they want this for the redesign...

mfb’s picture

Assigned: Unassigned » mfb
mfb’s picture

Status: Active » Needs review
StatusFileSize
new4.91 KB

add block display for existing project_issue_project view.

dww’s picture

Status: Needs review » Fixed

Cleaned this up a bit, tested, and committed to HEAD:

http://drupal.org/cvs?commit=194756

Note that I ripped out a bunch of the junk that views includes by default in the exported views, e.g. data about argument validator plugins we're not even using, etc. I also changed the default title of this block to just "Recent issues" since I think that makes a lot more sense.

See also #428396: Project node views argument validator generates SQL error for numeric project nids.

Thanks!
-Derek

dww’s picture

I wanted to add a filter to this so it only shows open issues. That led me to discover and fix #429190: "Special" project issue views filters only work for exposed filters. ;) So, I just committed a change to this default view to add a (working) non-exposed filter on open issues. ;)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

dww’s picture

Status: Closed (fixed) » Needs work
Issue tags: +needs drupal.org deployment

Forgot to mark that we need to deploy this on d.o:
- deploy the code
- clear views cache
- enable/place/configure the block

dww’s picture

Status: Needs work » Fixed
Issue tags: -needs drupal.org deployment

now deployed on d.o.

Status: Fixed » Closed (fixed)
Issue tags: -drupal.org redesign, -download & extend

Automatically closed -- issue fixed for 2 weeks with no activity.