1
0
mirror of https://github.com/meineerde/redmine.git synced 2025-12-19 15:01:14 +00:00

Move edit and delete buttons for queries to the buttons section (#28602).

Patch by Bernhard Rohloff.


git-svn-id: http://svn.redmine.org/redmine/trunk@17413 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Go MAEDA 2018-06-24 01:53:02 +00:00
parent 7dbd9e8c3b
commit 4b552f4c08

View File

@ -1,9 +1,5 @@
<% @gantt.view = self %> <% @gantt.view = self %>
<div class="contextual"> <div class="contextual">
<% if !@query.new_record? && @query.editable_by?(User.current) %>
<%= link_to l(:button_edit), edit_query_path(@query, :gantt => 1), :class => 'icon icon-edit' %>
<%= delete_link query_path(@query, :gantt => 1) %>
<% end %>
</div> </div>
<h2><%= @query.new_record? ? l(:label_gantt) : @query.name %></h2> <h2><%= @query.new_record? ? l(:label_gantt) : @query.name %></h2>
@ -80,6 +76,10 @@
"$('#query_form').attr('action', '#{ @project ? new_project_query_path(@project) : new_query_path }').submit();", "$('#query_form').attr('action', '#{ @project ? new_project_query_path(@project) : new_query_path }').submit();",
:class => 'icon icon-save' %> :class => 'icon icon-save' %>
<% end %> <% end %>
<% if !@query.new_record? && @query.editable_by?(User.current) %>
<%= link_to l(:button_edit), edit_query_path(@query, :gantt => 1), :class => 'icon icon-edit' %>
<%= delete_link query_path(@query, :gantt => 1) %>
<% end %>
</p> </p>
</div> </div>
<% end %> <% end %>