Sha256: 921be25b1605dcaf7da9970e817effb99f78f64ad27b20b4f7d50030a875fb01
Contents?: true
Size: 573 Bytes
Versions: 20
Compression:
Stored size: 573 Bytes
Contents
module RocketCMS module Controllers module News extend ActiveSupport::Concern def index @news = model.enabled.after_now.by_date unless RocketCMS.configuration.news_per_page.nil? @news = @news.page(params[:page]) end end def show @news = model.after_now.find(params[:id]) end private def model ::News end def page_title if @news.class.name == 'News' @news.page_title else super end end end end end
Version data entries
20 entries across 20 versions & 1 rubygems