Sha256: 93cc04fdf13c66feaa667dff289d4ef1f54784bd5a33cdfecd6d24873cc19e05
Contents?: true
Size: 570 Bytes
Versions: 109
Compression:
Stored size: 570 Bytes
Contents
module RocketCMS module Controllers module News extend ActiveSupport::Concern def index @news = model.enabled.after_now.by_date unless RocketCMS.config.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 == model.name @news.page_title else super end end end end end
Version data entries
109 entries across 109 versions & 1 rubygems