Sha256: 5f319f69236028f9eaca3f43b4c30ff817231cd8ac2dc5ca2f3cd9be3663ec64
Contents?: true
Size: 560 Bytes
Versions: 1
Compression:
Stored size: 560 Bytes
Contents
# encoding: utf-8 module PagesCore module RssController extend ActiveSupport::Concern private def all_feed_items feeds = Page.enabled_feeds(locale, include_hidden: true) Page.where(parent_page_id: feeds) .order("published_at DESC") .published .limit(20) .localized(locale) end def render_rss(items, title: nil) @title = PagesCore.config.site_name @title += ": #{title}" if title @items = items render template: "feeds/pages", layout: false end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pages_core-3.5.1 | app/controllers/concerns/pages_core/rss_controller.rb |