page redirect with redirect capturing

This commit is contained in:
2022-12-19 21:42:03 +02:00
parent f61ce40e71
commit ca029d274c
5 changed files with 29 additions and 3 deletions

View File

@ -10,6 +10,13 @@ module Merged
end
def update
@page.add_redirect
@page.name = params[:name]
@page.save
redirect_to page_path(@page) , notice: "Page renamed"
end
def create
name = params[:name]
message = Page.check_name(name)