summaryrefslogtreecommitdiffstats
path: root/app/views/context_menus/issues.html.erb
diff options
context:
space:
mode:
authorJean-Baptiste Barth <jeanbaptiste.barth@gmail.com>2010-09-03 19:54:24 +0000
committerJean-Baptiste Barth <jeanbaptiste.barth@gmail.com>2010-09-03 19:54:24 +0000
commita2ce6e236c397a527deb18cc2196371855d27c41 (patch)
tree80bbf34abb631a5435b24ff35a5fa8ce13286ebb /app/views/context_menus/issues.html.erb
parentc1068bf0cd32df1edf9b1b69e76e30af84692b7c (diff)
downloadredmine-a2ce6e236c397a527deb18cc2196371855d27c41.tar.gz
redmine-a2ce6e236c397a527deb18cc2196371855d27c41.zip
Allow mass status update through context menu. #3411
NB: it cannot be done with issues from different projects, same as other fields. This will be addressed separately, see #5332. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4055 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/context_menus/issues.html.erb')
-rw-r--r--app/views/context_menus/issues.html.erb15
1 files changed, 9 insertions, 6 deletions
diff --git a/app/views/context_menus/issues.html.erb b/app/views/context_menus/issues.html.erb
index dc11b5fdb..efd8cde0e 100644
--- a/app/views/context_menus/issues.html.erb
+++ b/app/views/context_menus/issues.html.erb
@@ -4,19 +4,22 @@
<% if !@issue.nil? -%>
<li><%= context_menu_link l(:button_edit), {:controller => 'issues', :action => 'edit', :id => @issue},
:class => 'icon-edit', :disabled => !@can[:edit] %></li>
+<% else %>
+ <li><%= context_menu_link l(:button_edit), {:controller => 'issues', :action => 'bulk_edit', :ids => @issues.collect(&:id)},
+ :class => 'icon-edit', :disabled => !@can[:edit] %></li>
+<% end %>
+
+ <% unless @allowed_statuses.empty? %>
<li class="folder">
<a href="#" class="submenu" onclick="return false;"><%= l(:field_status) %></a>
<ul>
<% @statuses.each do |s| -%>
- <li><%= context_menu_link s.name, {:controller => 'issues', :action => 'update', :id => @issue, :issue => {:status_id => s}, :back_url => @back}, :method => :put,
- :selected => (s == @issue.status), :disabled => !(@can[:update] && @allowed_statuses.include?(s)) %></li>
+ <li><%= context_menu_link s.name, {:controller => 'issues', :action => 'bulk_edit', :ids => @issues.collect(&:id), :issue => {:status_id => s}, :back_url => @back}, :method => :post,
+ :selected => (@issue && s == @issue.status), :disabled => !(@can[:update] && @allowed_statuses.include?(s)) %></li>
<% end -%>
</ul>
</li>
-<% else %>
- <li><%= context_menu_link l(:button_edit), {:controller => 'issues', :action => 'bulk_edit', :ids => @issues.collect(&:id)},
- :class => 'icon-edit', :disabled => !@can[:edit] %></li>
-<% end %>
+ <% end %>
<% unless @trackers.nil? %>
<li class="folder">