diff --git a/app/views/admin/admin_users/_admin_user.html.haml b/app/views/admin/admin_users/_admin_user.html.haml index c839cff..07e264f 100644 --- a/app/views/admin/admin_users/_admin_user.html.haml +++ b/app/views/admin/admin_users/_admin_user.html.haml @@ -4,4 +4,4 @@ %td= admin_user.last_sign_in_ip %td{ class: :actions } - unless admin_user == current_admin_user - = link_to 'Delete', admin_admin_user_path(admin_user), method: :delete, confirm: 'Are you sure you wish to delete this Admin User?' + = link_to 'Delete', admin_admin_user_path(admin_user), method: :delete, data: { confirm: 'Are you sure you wish to delete this Admin User?' } diff --git a/app/views/admin/categories/_category.html.haml b/app/views/admin/categories/_category.html.haml index 815c28c..8ab6237 100644 --- a/app/views/admin/categories/_category.html.haml +++ b/app/views/admin/categories/_category.html.haml @@ -4,4 +4,4 @@ %td= category.base_colour %td{ class: :actions } = link_to 'Edit', edit_admin_category_path(category) - = link_to 'Destroy', [:admin, category], confirm: 'Are you sure?', method: :delete + = link_to 'Destroy', [:admin, category], data: { confirm: 'Are you sure?' }, method: :delete diff --git a/app/views/admin/pages/_page.html.haml b/app/views/admin/pages/_page.html.haml index bd8c64c..458f405 100644 --- a/app/views/admin/pages/_page.html.haml +++ b/app/views/admin/pages/_page.html.haml @@ -4,4 +4,4 @@ %td{ class: :actions } = link_to 'Show', [:admin, page] = link_to 'Edit', edit_admin_page_path(page) - = link_to 'Destroy', [:admin, page], confirm: 'Are you sure?', method: :delete + = link_to 'Destroy', [:admin, page], data: { confirm: 'Are you sure?' }, method: :delete diff --git a/app/views/admin/photos/_photo.html.haml b/app/views/admin/photos/_photo.html.haml index ff49c18..5d6d7d8 100644 --- a/app/views/admin/photos/_photo.html.haml +++ b/app/views/admin/photos/_photo.html.haml @@ -2,4 +2,4 @@ = link_to image_tag(photo.image.admin.url, title: photo.title), photo.image.url .actions = link_to 'Edit', edit_admin_photo_path(photo) - = link_to 'Destroy', [:admin, photo], confirm: 'Are you sure?', method: :delete + = link_to 'Destroy', [:admin, photo], data: { confirm: 'Are you sure?' }, method: :delete