プロジェクト

全般

プロフィール

Vote #79741

完了

Add "Target Version" to the list of "Available columns" in "Spent time" Tab

Admin Redmine さんが3年以上前に追加. 3年以上前に更新.

ステータス:
Closed
優先度:
通常
担当者:
-
カテゴリ:
Time tracking_13
対象バージョン:
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
13
version_id:
127
issue_org_id:
30346
author_id:
26413
assigned_to_id:
332
comments:
18
status_id:
5
tracker_id:
2
plus1:
1
affected_version:
closed_on:
affected_version_id:
ステータス-->[Closed]

説明

I am evaluating last Redmine version (v4.0.0), and I have discovered that "Target Version" is missing at "Spent time" Tab in the list of "Available columns" while selecting columns for timelogs. Therefore, CSV export from "Spent time" TAB is also missing that valuable informatin for further spent time analysis.

It is clear that versions are tied to projects, and same "Target Version" literal in different projects might not be the same version, therefore might lead to confusion.
But, "Target Version" together with "Project" information (that is already selectable at "Available columns") can avoid any unclearness.


journals

In which version of Redmine did you see the "Target Version" (Version) as available column in "Spent time" tab? I've double checked now in Redmine 3.4 and Redmine 4.0 and is not available as column, it is available as filter and group criteria in the Reports tab (not Details). Please see below screenshots.

!{width:50%; border: 1px solid grey}.filter.png!

!{width:50%; border: 1px solid grey}.report.png!

--------------------------------------------------------------------------------
You are right. There is no such column in previous versions. Therefore this issue might be evaluated not as deffect but as a new feature.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
What about this issue? Is it going to plan to be added for next redmine version?

I think it's quite easy to implement and very useful and demanded. I don't know too much about redmine source code but I think patch would be very similar to this one: https://www.redmine.org/issues/28391
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
+1

Spent time tab has 4 types of filters for core fields of issues. They are Tracker, Status, Target version, and Category. However, only Target version is not included in available columns. I think it is quite odd that the field can be used as a filter is not included in available columns.

I think the target version field should have been added to available columns when #23401 was implemented.

*Before r15738:*
|_. Field |_. Filters |_. Available columns |
| Tracker |=. - |=. - |
| Status |=. - |=. - |
| Target version |=. ✓ |=. - |

*r15738:*
|_. Field |_. Filters |_. Available columns |
| Tracker |=. ✓ |=. ✓ |
| Status |=. ✓ |=. ✓ |
| Target version |=. ✓ |=. - |

--------------------------------------------------------------------------------
Here is a patch for this feature. Test results "here":https://gitlab.com/redmine-org/redmine/pipelines/93609621.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Marius BALTEANU wrote:
> Here is a patch for this feature. Test results "here":https://gitlab.com/redmine-org/redmine/pipelines/93609621.

There was an error in my proposed patch, I'll repost the patch soon.
--------------------------------------------------------------------------------
Here it is.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Thank you for posting the patch. But I had to change it as follows. Without the change, the id of the version is shown in the column instead of the name.

Setting the target version to 4.1.0.

<pre><code class="diff">
diff --git a/app/models/time_entry_query.rb b/app/models/time_entry_query.rb
index 77929e740..ed0d4dfbd 100644
--- a/app/models/time_entry_query.rb
+++ b/app/models/time_entry_query.rb
@@ -34,7 +34,7 @@ class TimeEntryQuery < Query
QueryAssociationColumn.new(:issue, :tracker, :caption => :field_tracker, :sortable => "#{Tracker.table_name}.position"),
QueryAssociationColumn.new(:issue, :status, :caption => :field_status, :sortable => "#{IssueStatus.table_name}.position"),
QueryAssociationColumn.new(:issue, :category, :caption => :field_category, :sortable => "#{IssueCategory.table_name}.name"),
- QueryAssociationColumn.new(:issue, :fixed_version_id, :caption => :field_fixed_version, :sortable => Version.fields_for_order_statement),
+ QueryAssociationColumn.new(:issue, :fixed_version, :caption => :field_fixed_version, :sortable => Version.fields_for_order_statement),
QueryColumn.new(:comments),
QueryColumn.new(:hours, :sortable => "#{TimeEntry.table_name}.hours", :totalable => true),
]
</code></pre>
--------------------------------------------------------------------------------
Go MAEDA wrote:
> Thank you for posting the patch. But I had to change it as follows. Without the change, the id of the version is shown in the column instead of the name.
>
> Setting the target version to 4.1.0.
>
> [...]

Indeed, @:fixed_version@ should be, I think I've mixed up some things before posting the patch.
--------------------------------------------------------------------------------
Committed the patch. Thank you.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------


related_issues

relates,New,14130,Spent Time Report Filter options
relates,Closed,23401,Add tracker and status columns/filters to detailed timelog
relates,Closed,28391,Add issue category filter and column to spent time queries
relates,Closed,32478,Add missing fixture to TimelogControllerTest

Admin Redmine さんが3年以上前に更新

  • カテゴリTime tracking_13 にセット
  • 対象バージョン4.1.0_127 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0