Sha256: b9d68d64c895acef4b0305cd0864eae53df29ab4afa44a9f357c29d17ccee090
Contents?: true
Size: 635 Bytes
Versions: 88
Compression:
Stored size: 635 Bytes
Contents
# frozen_string_literal: true module Decidim module Blogs module Admin # Base controller for the administration of this module. It inherits from # Decidim's admin base controller in order to inherit the layout and other # convenience methods relevant to a this component. class ApplicationController < Decidim::Admin::Components::BaseController helper_method :posts, :post def posts @posts ||= Post.where(component: current_component).page(params[:page]).per(15) end def post @post ||= posts.find(params[:id]) end end end end end
Version data entries
88 entries across 88 versions & 1 rubygems