Class: Pageflow::RevisionsController
Instance Method Summary
collapse
#delegate_to_rack_app!, #dispatch
Instance Method Details
#depublish_current ⇒ Object
26
27
28
29
30
31
32
|
# File 'app/controllers/pageflow/revisions_controller.rb', line 26
def depublish_current
entry = Entry.find(params[:entry_id])
authorize!(:publish, entry)
entry.revisions.depublish_all
redirect_to(main_app.admin_entry_path(entry))
end
|
#show ⇒ Object
10
11
12
13
14
15
16
|
# File 'app/controllers/pageflow/revisions_controller.rb', line 10
def show
revision = Revision.find(params[:id])
authorize!(:show, revision)
entry = PublishedEntry.new(revision.entry, revision)
delegate_to_entry_type_frontend_app!(entry)
end
|
#stylesheet ⇒ Object
18
19
20
21
22
23
24
|
# File 'app/controllers/pageflow/revisions_controller.rb', line 18
def stylesheet
revision = Revision.find(params[:id])
@entry = PublishedEntry.new(revision.entry, revision)
render template: 'pageflow/entries/stylesheet'
end
|