rename route to page (because that is what we show
This commit is contained in:
parent
e09f2935f1
commit
e823ac9d16
@ -104,12 +104,12 @@ mount Merged::Engine => "/merged"
|
||||
|
||||
Create route to serve content.
|
||||
```ruby
|
||||
get ":id" , to: "merged/view#view" , id: :id
|
||||
get ":id" , to: "merged/view#page" , id: :id
|
||||
```
|
||||
|
||||
If Merged served the root:
|
||||
```ruby
|
||||
root "merged/view#view" , id: 'index'
|
||||
root "merged/view#page" , id: 'index'
|
||||
```
|
||||
|
||||
### Stylesheets
|
||||
|
@ -1,7 +1,7 @@
|
||||
module Merged
|
||||
class ViewController < ::ApplicationController
|
||||
|
||||
def view
|
||||
def page
|
||||
@page = Page.find_by_name(params[:id])
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user