Sha256: 6b5062effbb330775e6fd2c572e0a0c95ab2498166ba38588f1395b852c5392c
Contents?: true
Size: 462 Bytes
Versions: 44
Compression:
Stored size: 462 Bytes
Contents
require_dependency "phcpress/application_controller" module Phcpress class Api::V1::PostsController < ApplicationController # Only Responds to API Requests respond_to :json # Article Category API def index @article_posts = Article::Post.where(poststatus: 'published').order('created_at ASC') end # Article Show def show @article_post = Article::Post.where(poststatus: published).find(params[:id]) end end end
Version data entries
44 entries across 44 versions & 1 rubygems