Adds category to the issue context menu (#1684).

git-svn-id: http://redmine.rubyforge.org/svn/trunk@1707 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2008-07-28 18:00:30 +00:00
parent 198a8c602d
commit c3f9575eaf
1 changed files with 13 additions and 0 deletions

View File

@ -44,6 +44,19 @@
:selected => @issue.assigned_to.nil?, :disabled => !@can[:update] %></li>
</ul>
</li>
<% unless @project.issue_categories.empty? -%>
<li class="folder">
<a href="#" class="submenu"><%= l(:field_category) %></a>
<ul>
<% @project.issue_categories.each do |u| -%>
<li><%= context_menu_link u.name, {:controller => 'issues', :action => 'edit', :id => @issue, 'issue[category_id]' => u, :back_to => @back}, :method => :post,
:selected => (u == @issue.category), :disabled => !@can[:update] %></li>
<% end -%>
<li><%= context_menu_link l(:label_none), {:controller => 'issues', :action => 'edit', :id => @issue, 'issue[category_id]' => '', :back_to => @back}, :method => :post,
:selected => @issue.category.nil?, :disabled => !@can[:update] %></li>
</ul>
</li>
<% end -%>
<li class="folder">
<a href="#" class="submenu"><%= l(:field_done_ratio) %></a>
<ul>