]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/issues/show.html.erb
Refactor reportable_url helper to focus on just the title choices.
[rails.git] / app / views / issues / show.html.erb
index 3bef038005e9223adb367e357f7cd1e17b1b2597..fa8afa2331dc20f647abcb209bfd6b35d26c2f65 100644 (file)
@@ -1,6 +1,6 @@
 <% content_for :heading do %>
 <h2><%= t ".title", :status => @issue.status.humanize, :issue_id => @issue.id %></h2>
-<p><%= report_type(@issue.reportable_type) %> : <%= reportable_url(@issue.reportable) %></p>
+<p><%= @issue.reportable.model_name.human %> : <%= reportable_url(@issue.reportable) %></p>
 <p class="deemphasize">
   <small>
     <%= @issue.assigned_role %>
@@ -46,7 +46,7 @@
       <% if @related_issues.count > 1 %>
         <% @related_issues.each do |issue| %>
           <% if issue.id != @issue.id %>
-            <%= reports_url(issue) %> <br/>
+            <%= link_to reportable_title(issue.reportable), issue %> <br/>
           <% end %>
         <% end %>
       <% else %>