Do not show section edit links for wiki page history (#2222).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7830 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
6fc245327c
commit
2770e28535
|
@ -85,6 +85,7 @@ class WikiController < ApplicationController
|
|||
end
|
||||
end
|
||||
@editable = editable?
|
||||
@sections_editable = @editable && User.current.allowed_to?(:edit_wiki_pages, @page.project) && params[:version].nil?
|
||||
render :action => 'show'
|
||||
end
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<div class="wiki wiki-page">
|
||||
<%= textilizable content, :text, :attachments => content.page.attachments,
|
||||
:edit_section_links => (content.is_a?(WikiContent) && @editable && User.current.allowed_to?(:edit_wiki_pages, @page.project) && {:controller => 'wiki', :action => 'edit', :project_id => @page.project, :id => @page.title}) %>
|
||||
:edit_section_links => (@sections_editable && {:controller => 'wiki', :action => 'edit', :project_id => @page.project, :id => @page.title}) %>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue