diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-17 11:22:30 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-17 11:22:30 +0000 |
commit | 04cf448648458bbbe9cfd7b4559522d3a3bb1595 (patch) | |
tree | 5cd6509a6761a11dcffaa141c975fd16e260c003 /lib | |
parent | 186329ef04ad70df3f05dade00cc1f2b00f5ce35 (diff) | |
download | redmine-04cf448648458bbbe9cfd7b4559522d3a3bb1595.tar.gz redmine-04cf448648458bbbe9cfd7b4559522d3a3bb1595.zip |
code cleanup: rubocop: fix Layout/ElseAlignment in lib/redmine/export/pdf/issues_pdf_helper.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18705 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib')
-rw-r--r-- | lib/redmine/export/pdf/issues_pdf_helper.rb | 39 |
1 files changed, 20 insertions, 19 deletions
diff --git a/lib/redmine/export/pdf/issues_pdf_helper.rb b/lib/redmine/export/pdf/issues_pdf_helper.rb index 6f86e1d55..8b1e59ae2 100644 --- a/lib/redmine/export/pdf/issues_pdf_helper.rb +++ b/lib/redmine/export/pdf/issues_pdf_helper.rb @@ -369,27 +369,28 @@ module Redmine # fetch row values def fetch_row_values(issue, query, level) query.inline_columns.collect do |column| - s = if column.is_a?(QueryCustomFieldColumn) - cv = issue.visible_custom_field_values.detect {|v| v.custom_field_id == column.custom_field.id} - show_value(cv, false) - else - value = issue.send(column.name) - case column.name - when :subject - value = " " * level + value - when :attachments - value = value.to_a.map {|a| a.filename}.join("\n") - end - if value.is_a?(Date) - format_date(value) - elsif value.is_a?(Time) - format_time(value) - elsif value.is_a?(Float) - sprintf "%.2f", value + s = + if column.is_a?(QueryCustomFieldColumn) + cv = issue.visible_custom_field_values.detect {|v| v.custom_field_id == column.custom_field.id} + show_value(cv, false) else - value + value = issue.send(column.name) + case column.name + when :subject + value = " " * level + value + when :attachments + value = value.to_a.map {|a| a.filename}.join("\n") + end + if value.is_a?(Date) + format_date(value) + elsif value.is_a?(Time) + format_time(value) + elsif value.is_a?(Float) + sprintf "%.2f", value + else + value + end end - end s.to_s end end |