Code cleanup.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11070 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2012-12-22 10:57:01 +00:00
parent 6c15812d96
commit a4f989a5e0
2 changed files with 9 additions and 10 deletions

View File

@ -1,11 +1,10 @@
<h2><%= @copy ? l(:button_copy) : l(:label_bulk_edit_selected_issues) %></h2> <h2><%= @copy ? l(:button_copy) : l(:label_bulk_edit_selected_issues) %></h2>
<ul><%= @issues.collect {|i| <ul>
content_tag('li', <% @issues.each do |issue| %>
link_to(h("#{i.tracker} ##{i.id}"), <%= content_tag 'li', link_to_issue(issue) %>
{ :action => 'show', :id => i } <% end %>
) + h(": #{i.subject}")) </ul>
}.join("\n").html_safe %></ul>
<%= form_tag({:action => 'bulk_update'}, :id => 'bulk_edit_form') do %> <%= form_tag({:action => 'bulk_update'}, :id => 'bulk_edit_form') do %>
<%= @issues.collect {|i| hidden_field_tag('ids[]', i.id)}.join("\n").html_safe %> <%= @issues.collect {|i| hidden_field_tag('ids[]', i.id)}.join("\n").html_safe %>

View File

@ -1,10 +1,10 @@
<h2><%= l(:label_bulk_edit_selected_time_entries) %></h2> <h2><%= l(:label_bulk_edit_selected_time_entries) %></h2>
<ul> <ul>
<%= @time_entries.collect {|i| content_tag('li', <% @time_entries.each do |entry| %>
link_to(h("#{i.spent_on.strftime("%Y-%m-%d")} - #{i.project}: #{l(:label_f_hour_plural, :value => i.hours)}"), <%= content_tag 'li',
{ :action => 'edit', :id => i }) link_to("#{format_date(entry.spent_on)} - #{entry.project}: #{l(:label_f_hour_plural, :value => entry.hours)}", edit_time_entry_path(entry)) %>
)}.join("\n").html_safe %> <% end %>
</ul> </ul>
<%= form_tag(:action => 'bulk_update') do %> <%= form_tag(:action => 'bulk_update') do %>