プロジェクト

全般

プロフィール

« | » 

リビジョン 3f7c9b0b

高徹 高橋 徹 さんが約6年前に追加

[phase-8]introduced security and authorization

差分を表示:

app/views/glossary_terms/show.html.erb
<div class="contextual">
<%= link_to l(:button_edit), edit_project_glossary_term_path, class: 'icon icon-edit' %>
<%= link_to l(:button_delete), project_glossary_term_path, method: :delete,
data: {confirm: l(:text_are_you_sure)}, class: 'icon icon-del' %>
<%= link_to_if_authorized l(:button_edit),
{ controller: :glossary_terms, action: :edit, project_id: @project },
class: 'icon icon-edit' %>
<%= link_to_if_authorized l(:button_delete),
{ controller: :glossary_terms, action: :destroy,
id: @term, project_id: @project },
method: :delete, data: {confirm: l(:text_are_you_sure)}, class: 'icon icon-del' %>
</div>
<%= render partial: 'sidebar' %>

他の形式にエクスポート: Unified diff