Issue tracker: hide closed issues

Started by Radiant, Tue 11/03/2014 14:24:46

Previous topic - Next topic

Radiant

Since the primary purpose of the issue tracker is to see which issues are ongoing (newly reported or still being worked on), it would be more convenient if the default view of the issue tracker (e.g. http://www.adventuregamestudio.co.uk/forums/index.php?project=3;area=issues ) would either hide closed and solved issues, or be sorted so that these issues appear at the bottom.

Crimson Wizard

I'd wish we have ANY kind of sorting work there :)

AGA

Hahaha, no.  Sorry.  Any changes you want made to the tracker, you'll have to do them yourselves.  It's a standard install of SMF Project Tracker, but that project is now dead.  It's really far too complicated, and kinda poorly written, for me to spend ages working out how to make it more usable.  The source is at the link I posted, if anyone else fancies having a go though!

Radiant

I've done some experimenting...

You can sort things by appending them to the URL: http://www.adventuregamestudio.co.uk/forums/index.php?project=5;area=issues&sort=status
Alternatively, you can find one category by also appending that to the URL: http://www.adventuregamestudio.co.uk/forums/index.php?project=5;area=issues&status=1
(and you can combine the two, if you want)

CW, is that the kind of thing you're looking for?

AGA

If it's as something as simple as adding a link to 'sort by x' I'm happy to do that of course.  But expanding the Project's functionality is a bit much.

Crimson Wizard

You can filter by category by clicking on category name.

Peder 🚀

#6
Or it looks like you could just edit this file: IssueList.php on line 37/38
Code: php

		$context['sort_by'] = 'updated';
		$_REQUEST['sort'] = 'i.updated';


Change "updated" with "status"

(Though it seems all though that will put any resolved/closed issues below new/assigned ones it doesn't seem to take into picture the date they were updated.. But it's probably not too hard to sort out).

AGA

Okay, great.  If someone wants to fiddle to make the existing sorting thing have weighting I'm happy to hack it in.

Peder 🚀

#8
Ok, after scanning through the files I think this could work:
Code: php

		$context['sort_by'] = 'status';
		$_REQUEST['sort'] = 'i.status ASC, i.updated';


These are the same lines as mentioned above. (And it seems really only the second one really does anything important)
(It might require some more small code, if this doesn't work I'll set up a local installation of SMF and test it out there.)

[EDIT]
I changed the code and it should definitely work now! :)

Peder 🚀

Sorry for double post but I noticed a "bug" with the issue tracker, where when you add/edit/delete categories in a project it will try and send you to the project tracker section in the forum admin area.

To fix this you can change line 591 in the file ProjectModule-Admin.php from:

Code: php

redirectexit('action=admin;area=manageprojects;section=categories');


to:

Code: php

redirectexit(project_get_url(array('project' => $project, 'area' => 'admin', 'sa' => 'category')));

AGA


Peder 🚀


AGA

Sorry, when I saw "I changed the code" I thought you meant you'd actually edited the forum source files!  Made the changes now, thanks.

Peder 🚀


Crimson Wizard

#14
Erm, what did you do to sorting? :( Before it sorted by last update, now it sorts by status.

EDIT: Oh, I see now, it sorts both by status AND update time.

UPD: I have to disagree with this. It's not uncommon when you need to see recently updated issues regardless of the status.
For example, "New" and "Confirmed" status both marks tasks and bugs, the difference is pretty vague, besides "Confirmed" bugs means that their presence was checked, but "Confirmed" issues are listed after "New" ones.
"Resolved" status means that developer did some changes but the issue is yet to be tested and confirmed working. When there are many "New" issues, "Resolved" will get somewhere to the end of the list, and users who were waiting for them to be fixed won't notice the update.

Peder 🚀

#15
So basically the preferred result is to show closed and resolved at the bottom but have the rest ordered by when it was updated? :)

If AGA changes the previous code with this:
Code: php
i.status = 6 ASC, i.status = 5 ASC, i.updated


It will sort closed at the bottom, resolved above, then the rest all by when they were last updated!

AGA


SMF spam blocked by CleanTalk