Merge branch '19954-permission-dedup-doc'
[arvados.git] / apps / workbench / app / views / application / _delete_object_button.html.erb
index 6d6383e24ec02c6f460f69e738ace017d52082d1..4db3aea03523b3a53a0eac512b7b5b11ffa2d6ed 100644 (file)
@@ -1,5 +1,9 @@
-<% if object.editable? %>
-  <%= link_to({action: 'destroy', id: object.uuid}, method: :delete, remote: true, data: {confirm: "Really delete #{object.class_for_display.downcase} '#{object.friendly_link_name}'?"}) do %>
+<%# Copyright (C) The Arvados Authors. All rights reserved.
+
+SPDX-License-Identifier: AGPL-3.0 %>
+
+<% if object.deletable? %>
+  <%= link_to({controller: object.class.table_name, action: 'destroy', id: object.uuid}, method: :delete, remote: true, data: {confirm: "Really delete #{object.class_for_display.downcase} '#{object.friendly_link_name}'?"}) do %>
     <i class="glyphicon glyphicon-trash"></i>
   <% end %>
 <% end %>