From 3e14a86bcb38ae810144f96b0d06e16a938920a6 Mon Sep 17 00:00:00 2001 From: Toru Takahashi Date: Tue, 14 Aug 2018 14:12:37 +0900 Subject: [PATCH] [phase-20]Add edit and delete icons in category index --- app/views/glossary_categories/index.html.erb | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/app/views/glossary_categories/index.html.erb b/app/views/glossary_categories/index.html.erb index 54062b7..e9b6657 100644 --- a/app/views/glossary_categories/index.html.erb +++ b/app/views/glossary_categories/index.html.erb @@ -23,6 +23,15 @@ <%= link_to category.name, [@project, category] %> <%= reorder_handle(category, url: project_glossary_category_path(@project, category)) %> + <%= link_to_if_authorized l(:button_edit), { + controller: :glossary_categories, action: :edit, id: category, + project_id: @project + }, class: 'icon icon-edit' %> + <%= link_to_if_authorized l(:button_delete), { + controller: :glossary_categories, action: :destroy, id: category, + project_id: @project + }, method: :delete, data: {confirm: l(:text_are_you_sure)}, + class: 'icon icon-del' %> <% end %>