From 24c9752018e1220ffe4a168aec9d6908acc2840d Mon Sep 17 00:00:00 2001 From: Mario Visic Date: Sat, 20 Aug 2011 17:13:06 +0800 Subject: [PATCH] Implemenation for hiding the destroy asset button. --- app/views/admin/theme_assets/_asset.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/admin/theme_assets/_asset.html.haml b/app/views/admin/theme_assets/_asset.html.haml index 99f0e080..23a81e03 100644 --- a/app/views/admin/theme_assets/_asset.html.haml +++ b/app/views/admin/theme_assets/_asset.html.haml @@ -9,5 +9,5 @@ %span!= t('.updated_at') %span.date= l asset.updated_at, :format => :short - - if edit + - if edit && can?(:destroy, asset) = link_to image_tag('admin/list/icons/trash.png'), admin_theme_asset_path(asset), :class => 'remove', :confirm => t('admin.messages.confirm'), :method => :delete