Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
neoteric-news / lib / neoteric-news / posts_controller.rb
Size: Mime:
module Neoteric
  module NewsPostsController
    def self.included(base)
      base.send :include, ::Neoteric::ArchiverController
      base.archiving base.new.post_class
    end

    def index
      @news_posts = post_class.published
    end

    def show
      @news_post = post_class.published.find(params[:id])
    end

    def post_class
      Neoteric::News.post_class
    end
  end
end