From e2c08c7b36e4fd270aed6691d4d8d8e216b4a4c8 Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Sun, 27 Jun 2021 07:18:58 +0000 Subject: Add total estimated hours, spent hours, total spent hours for issues to issue list API (#34857). MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Patch by Felix Schäfer and Takenori TAKAKI. git-svn-id: http://svn.redmine.org/redmine/trunk@21051 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/views/issues/index.api.rsb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'app/views') diff --git a/app/views/issues/index.api.rsb b/app/views/issues/index.api.rsb index 4bba32549..da60ea5c6 100644 --- a/app/views/issues/index.api.rsb +++ b/app/views/issues/index.api.rsb @@ -19,6 +19,11 @@ api.array :issues, api_meta(:total_count => @issue_count, :offset => @offset, :l api.done_ratio issue.done_ratio api.is_private issue.is_private api.estimated_hours issue.estimated_hours + api.total_estimated_hours issue.total_estimated_hours + if User.current.allowed_to?(:view_time_entries, issue.project) + api.spent_hours(issue.spent_hours) + api.total_spent_hours(issue.total_spent_hours) + end render_api_custom_values issue.visible_custom_field_values, api -- cgit v1.2.3