Commit 5aada8cc authored by Riyad Preukschas's avatar Riyad Preukschas

Move wiki delete button to the edit page

parent e54246d3
%h3.page_title Editing page %h3.page_title Editing page
%hr %hr
= render 'form' = render 'form'
.right
- if can? current_user, :admin_wiki, @project
= link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete, class: "btn small danger" do
Delete this page
\ No newline at end of file
...@@ -16,6 +16,3 @@ ...@@ -16,6 +16,3 @@
= markdown @wiki.content = markdown @wiki.content
%p.time Last edited by #{@wiki.user.name}, #{time_ago_in_words @wiki.created_at} ago %p.time Last edited by #{@wiki.user.name}, #{time_ago_in_words @wiki.created_at} ago
- if can? current_user, :admin_wiki, @project
= link_to project_wiki_path(@project, @wiki), confirm: "Are you sure you want to delete this page?", method: :delete do
Delete this page
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment