Sha256: 30e4f26a3a694e153fc841d6204a01e420820d1e6e4c99587847ac53386606f2

Contents?: true

Size: 336 Bytes

Versions: 13

Compression:

Stored size: 336 Bytes

Contents

module Qbrick
  module Api
    class PagesController < ActionController::Base
      layout :false
      respond_to :json

      def index
        I18n.locale = params[:locale]
        @pages = Qbrick::Page.unscoped.published.content_page.translated.order(position: :asc)

        render json: @pages.as_json
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
qbrick-2.7.1 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.7 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.10 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.9 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.8 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.7 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.6 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.5 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.4 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.3 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.2 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.1 app/controllers/qbrick/api/pages_controller.rb
qbrick-2.6.0 app/controllers/qbrick/api/pages_controller.rb