Class: Comfy::Admin::Cms::Revisions::PageController
- Inherits:
-
BaseController
- Object
- BaseController
- Comfy::Admin::Cms::Revisions::PageController
- Defined in:
- app/controllers/comfy/admin/cms/revisions/page_controller.rb
Instance Method Summary collapse
Instance Method Details
#show ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 |
# File 'app/controllers/comfy/admin/cms/revisions/page_controller.rb', line 5 def show @current_content = @record.fragments.each_with_object({}) do |b, c| c[b.identifier] = b.content end @versioned_content = @record.fragments.each_with_object({}) do |b, c| d = @revision.data["fragments_attributes"].detect { |r| r[:identifier] == b.identifier } c[b.identifier] = d.try(:[], :content) end render "comfy/admin/cms/revisions/show" end |