PHP 클래스 Corcel\PostBuilder

상속: extends Illuminate\Database\Eloquent\Builder
파일 보기 프로젝트 열기: jgrossi/corcel 1 사용 예제들

공개 메소드들

메소드 설명
paged ( integer $perPage = 10, integer $currentPage = 1 ) : Illuminate\Database\Eloquent\Collection Paginate the results
published ( ) : PostBuilder Get only published posts
slug ( $slug ) : PostBuilder Get only posts with a specific slug
status ( string $postStatus ) : PostBuilder Get only posts with a custom status
taxonomy ( $taxonomy, $term )
type ( string $type ) : PostBuilder Get only posts from a custom post type
typeIn ( array $type ) : PostBuilder Get only posts from an array of custom post types

메소드 상세

paged() 공개 메소드

Paginate the results
public paged ( integer $perPage = 10, integer $currentPage = 1 ) : Illuminate\Database\Eloquent\Collection
$perPage integer
$currentPage integer
리턴 Illuminate\Database\Eloquent\Collection

published() 공개 메소드

Get only published posts
public published ( ) : PostBuilder
리턴 PostBuilder

slug() 공개 메소드

Get only posts with a specific slug
public slug ( $slug ) : PostBuilder
리턴 PostBuilder

status() 공개 메소드

Get only posts with a custom status
public status ( string $postStatus ) : PostBuilder
$postStatus string
리턴 PostBuilder

taxonomy() 공개 메소드

public taxonomy ( $taxonomy, $term )

type() 공개 메소드

Get only posts from a custom post type
public type ( string $type ) : PostBuilder
$type string
리턴 PostBuilder

typeIn() 공개 메소드

Get only posts from an array of custom post types
public typeIn ( array $type ) : PostBuilder
$type array
리턴 PostBuilder