Class: Workarea::Api::Storefront::PagesController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/workarea/api/storefront/pages_controller.rb

Instance Method Summary collapse

Methods inherited from ApplicationController

#cache_page, #skip_session

Methods included from UserActivity

#assert_current_user_activity_id, #current_user_activity_id, #user_activity

Methods included from Authentication

#authentication?, #current_user

Instance Method Details

#showObject



7
8
9
10
# File 'app/controllers/workarea/api/storefront/pages_controller.rb', line 7

def show
  model = Content::Page.active.find_by(slug: params[:id])
  @page = Workarea::Storefront::PageViewModel.new(model, view_model_options)
end