Sha256: 685659593ad768eb04e68063afe1f91538e843725dd438ffff81ffb2a61d0a00
Contents?: true
Size: 468 Bytes
Versions: 1
Compression:
Stored size: 468 Bytes
Contents
require_dependency "phcpresspro/application_controller" module Phcpresspro 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
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
phcpresspro-22.1.0 | app/controllers/phcpresspro/api/v1/posts_controller.rb |