]> source.dussan.org Git - redmine.git/commitdiff
code layout clean up IssuesController#show
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 22 Nov 2019 04:24:53 +0000 (04:24 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 22 Nov 2019 04:24:53 +0000 (04:24 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@19149 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/controllers/issues_controller.rb

index cd953182e6244001e4f525789a2c5db07921fbe1..73637095b751d797c528ca4f4f260de77ea87658 100644 (file)
@@ -89,8 +89,11 @@ class IssuesController < ApplicationController
   def show
     @journals = @issue.visible_journals_with_index
     @has_changesets = @issue.changesets.visible.preload(:repository, :user).exists?
-    @relations = @issue.relations.select {|r| r.other_issue(@issue) && r.other_issue(@issue).visible? }
-
+    @relations =
+      @issue.relations.
+        select {|r|
+          r.other_issue(@issue) && r.other_issue(@issue).visible?
+        }
     @journals.reverse! if User.current.wants_comments_in_reverse_order?
 
     if User.current.allowed_to?(:view_time_entries, @project)
@@ -112,9 +115,13 @@ class IssuesController < ApplicationController
         @changesets = @issue.changesets.visible.preload(:repository, :user).to_a
         @changesets.reverse! if User.current.wants_comments_in_reverse_order?
       }
-      format.atom { render :template => 'journals/index', :layout => false, :content_type => 'application/atom+xml' }
+      format.atom {
+        render :template => 'journals/index', :layout => false,
+        :content_type => 'application/atom+xml'
+      }
       format.pdf  {
-        send_file_headers! :type => 'application/pdf', :filename => "#{@project.identifier}-#{@issue.id}.pdf"
+        send_file_headers!(:type => 'application/pdf',
+                           :filename => "#{@project.identifier}-#{@issue.id}.pdf")
       }
     end
   end