diff options
-rw-r--r-- | app/views/issues/_subtasks.html.erb | 12 | ||||
-rw-r--r-- | app/views/issues/show.html.erb | 11 |
2 files changed, 13 insertions, 10 deletions
diff --git a/app/views/issues/_subtasks.html.erb b/app/views/issues/_subtasks.html.erb new file mode 100644 index 000000000..c84b5baf9 --- /dev/null +++ b/app/views/issues/_subtasks.html.erb @@ -0,0 +1,12 @@ +<div class="contextual"> + <%= link_to_new_subtask(@issue) if User.current.allowed_to?(:manage_subtasks, @project) %> +</div> + +<p> + <strong><%=l(:label_subtask_plural)%></strong> + <%= render_descendants_stats(@issue) unless @issue.leaf? %> +</p> + +<%= form_tag({}, :data => {:cm_url => issues_context_menu_path}) do %> + <%= render_descendants_tree(@issue) unless @issue.leaf? %> +<% end %> diff --git a/app/views/issues/show.html.erb b/app/views/issues/show.html.erb index 6b84bdfb3..390728ada 100644 --- a/app/views/issues/show.html.erb +++ b/app/views/issues/show.html.erb @@ -105,16 +105,7 @@ end %> <% if !@issue.leaf? || User.current.allowed_to?(:manage_subtasks, @project) %> <hr /> <div id="issue_tree"> -<div class="contextual"> - <%= link_to_new_subtask(@issue) if User.current.allowed_to?(:manage_subtasks, @project) %> -</div> -<p> - <strong><%=l(:label_subtask_plural)%></strong> - <%= render_descendants_stats(@issue) unless @issue.leaf? %> -</p> -<%= form_tag({}, :data => {:cm_url => issues_context_menu_path}) do %> -<%= render_descendants_tree(@issue) unless @issue.leaf? %> -<% end %> +<%= render :partial => 'subtasks' %> </div> <% end %> |