Sha256: 24946295106dd21ebf5e09c00e1c452bd558cb1c87ab29a4e1422dd4951f7be6

Contents?: true

Size: 711 Bytes

Versions: 14

Compression:

Stored size: 711 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Meetings
    module Admin
      # This controller is the abstract class from which all other controllers of
      # this engine inherit.
      #
      # Note that it inherits from `Decidim::Components::BaseController`, which
      # override its layout and provide all kinds of useful methods.
      class ApplicationController < Decidim::Admin::Components::BaseController
        helper_method :meetings, :meeting

        def meetings
          @meetings ||= Meeting.where(component: current_component).page(params[:page]).per(15)
        end

        def meeting
          @meeting ||= meetings.find(params[:id])
        end
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
decidim-meetings-0.14.4 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.14.3 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.14.2 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.14.1 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.13.1 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.12.2 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.13.0 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.12.1 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.13.0.pre1 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.12.0 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.11.2 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.12.0.pre app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.11.1 app/controllers/decidim/meetings/admin/application_controller.rb
decidim-meetings-0.11.0.pre1 app/controllers/decidim/meetings/admin/application_controller.rb