summaryrefslogtreecommitdiffstats
path: root/app/controllers/wiki_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/wiki_controller.rb')
-rw-r--r--app/controllers/wiki_controller.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/app/controllers/wiki_controller.rb b/app/controllers/wiki_controller.rb
index 115f61157..6d3b44636 100644
--- a/app/controllers/wiki_controller.rb
+++ b/app/controllers/wiki_controller.rb
@@ -160,10 +160,10 @@ class WikiController < ApplicationController
call_hook(:controller_wiki_edit_after_save, { :params => params, :page => @page})
respond_to do |format|
- format.html { redirect_to :action => 'show', :project_id => @project, :id => @page.title }
+ format.html { redirect_to project_wiki_page_path(@project, @page.title) }
format.api {
if was_new_page
- render :action => 'show', :status => :created, :location => url_for(:controller => 'wiki', :action => 'show', :project_id => @project, :id => @page.title)
+ render :action => 'show', :status => :created, :location => project_wiki_page_path(@project, @page.title)
else
render_api_ok
end
@@ -200,13 +200,13 @@ class WikiController < ApplicationController
@original_title = @page.pretty_title
if request.post? && @page.update_attributes(params[:wiki_page])
flash[:notice] = l(:notice_successful_update)
- redirect_to :action => 'show', :project_id => @project, :id => @page.title
+ redirect_to project_wiki_page_path(@project, @page.title)
end
end
def protect
@page.update_attribute :protected, params[:protected]
- redirect_to :action => 'show', :project_id => @project, :id => @page.title
+ redirect_to project_wiki_page_path(@project, @page.title)
end
# show page history
@@ -262,7 +262,7 @@ class WikiController < ApplicationController
end
@page.destroy
respond_to do |format|
- format.html { redirect_to :action => 'index', :project_id => @project }
+ format.html { redirect_to project_wiki_index_path(@project) }
format.api { render_api_ok }
end
end
@@ -272,7 +272,7 @@ class WikiController < ApplicationController
@content = @page.content_for_version(params[:version])
@content.destroy
- redirect_to_referer_or :action => 'history', :id => @page.title, :project_id => @project
+ redirect_to_referer_or history_project_wiki_page_path(@project, @page.title)
end
# Export wiki to a single pdf or html file