##// END OF EJS Templates
Adds a helper for displaying a link to add a subtask (#12113)....
Jean-Philippe Lang -
r10450:b8fbb41d5f63
parent child
Show More
@@ -94,6 +94,11 module IssuesHelper
94 94 s.html_safe
95 95 end
96 96
97 # Returns a link for adding a new subtask to the given issue
98 def link_to_new_subtask(issue)
99 link_to(l(:button_add), {:controller => 'issues', :action => 'new', :project_id => issue.project, :issue => {:parent_issue_id => issue}})
100 end
101
97 102 class IssueFieldsRows
98 103 include ActionView::Helpers::TagHelper
99 104
@@ -93,7 +93,7 end %>
93 93 <hr />
94 94 <div id="issue_tree">
95 95 <div class="contextual">
96 <%= link_to(l(:button_add), {:controller => 'issues', :action => 'new', :project_id => @project, :issue => {:parent_issue_id => @issue}}) if User.current.allowed_to?(:manage_subtasks, @project) %>
96 <%= link_to_new_subtask(@issue) if User.current.allowed_to?(:manage_subtasks, @project) %>
97 97 </div>
98 98 <p><strong><%=l(:label_subtask_plural)%></strong></p>
99 99 <%= render_descendants_tree(@issue) unless @issue.leaf? %>
General Comments 0
You need to be logged in to leave comments. Login now