[31200] Allow deletion of colors

https://community.openproject.com/wp/31200
pull/7733/head
Oliver Günther 5 years ago
parent e4a686f389
commit 2ae00dc169
No known key found for this signature in database
GPG Key ID: A3A8BDAD7C0C552C
  1. 14
      app/views/colors/_form.html.erb

@ -29,7 +29,19 @@ See docs/COPYRIGHT.rdoc for more details.
<%= error_messages_for 'color' %>
<%= toolbar title: (color.new_record? ? t('timelines.new_color') : t('timelines.edit_color')) %>
<%= toolbar title: (color.new_record? ? t('timelines.new_color') : t('timelines.edit_color')) do %>
<% if color.persisted? %>
<li class="toolbar-item">
<%= link_to color_path(color),
method: :delete,
data: { confirm: t('text_are_you_sure') },
class: "button -danger" do %>
<%= op_icon 'button--icon icon-delete' %>
<span class="button--text"><%= t :button_delete %></span>
<% end %>
</li>
<% end %>
<% end %>
<fieldset class="form--fieldset">
<legend class="form--fieldset-legend"><%= t('timelines.properties') %></legend>

Loading…
Cancel
Save