Display Issues in a hierarchy (tree)
We have setup issues and child issues, for example, to complete a big task, we divide it into many small tasks, the parent task being the big one.
However the view on the issues page is not very informing even with the column parent task activated, what would be interesting is having a tree-like representation of the tasks.
is this possible?
#10 Updated by Daniel Albuschat over 10 years ago
For me, this is a big issue, too.
IMHO, the logic of the issue list should be changed to behave like this:
- Add a checkbox whether the changes described here should be applied, named something like "Show subtasks in tree view" (even without sorting by parent task). Default: Yes
- Add a checkbox whether the filter criteria should be applied to subtasks, too. It is surely not uncommon that you would like to filter parent tasks by priority, for example, but have all subtasks of these filtered tasks visible. Sometimes, however, you probably just want to see subtasks with the same, filtered priority.
- Change the issue list to filter only parent tasks.
- For each parent tasks, filter the corresponding subtasks and display them below (and indented to) the parent task
- The same procedure is done recursively for the subtasks' subtasks, too.
There are two ways to avoid multiple database queries for each parent task:
a) select a field has_subtasks as "case when exists (select * from issues subissue where subissue.parent_id=issue.parent_id) then 1 else 0 end as has_subtasks". With this, you can check whether you need to query for subtasks at all without executing another query.
b) Add a field "has_subtasks" in the table issues that is automatically updated by a trigger when a subtask has been added or removed (this makes updating a little bit slower, but selecting the issues much faster - especially for lists without or with a only a few subtasks)
What do you think, Jean-Philippe Lang?
Since this is a big issue for me (I just introduced Redmine in our company), I'd even try to implement this.
#12 Updated by Vitaly Klimov over 10 years ago
Please check my plugin - it solves this behavior:
#23 Updated by Robert Schneider about 8 years ago
The gantt diagram already contains it. But it is not enough.
I would create a new view for this. When the user is in the Tickets tab he or she should get the option to display the (existing) list view or the tree view. I think a tree view has the same value as a list, though they may provide different functions. Ideally, tree view and list view should be one thing. But this could be difficult to implement. That's why suggest to start a new view. A primitive tree view is better than no view.
#42 Updated by Bernhard Rohloff almost 2 years ago
Klaus Adler wrote:
We are using Vitaly Klimov Smart Sort Plugin. We want to upgrade, but the Plugin is not working with 4.1.
As far as the tree view is concerned you may have a look at this plugin here: https://www.redmine.org/plugins/redmine_issues_tree