PHP Класс Hootlex\Moderation\ModerationScope

Наследование: implements Illuminate\Database\Eloquent\Scope
Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
$extensions array All of the extensions to be added to the builder.

Открытые методы

Метод Описание
apply ( Builder $builder, Model $model ) : void Apply the scope to a given Eloquent query builder.
extend ( Builder $builder ) : void Extend the query builder with the needed functions.
remove ( Builder $builder, Model $model ) : void Remove the scope from the given Eloquent query builder.

Защищенные методы

Метод Описание
addApprove ( Builder $builder ) : void Add the Approve extension to the builder.
addPend ( Builder $builder ) : void Add the Postpone extension to the builder.
addPending ( Builder $builder ) : void Add the Pending extension to the builder.
addPostpone ( Builder $builder ) : void Add the Postpone extension to the builder.
addPostponed ( Builder $builder ) : void Add the Postponed extension to the builder.
addReject ( Builder $builder ) : void Add the Reject extension to the builder.
addRejected ( Builder $builder ) : void Add the Rejected extension to the builder.
addWithAnyStatus ( Builder $builder ) : void Add the with-any-status extension to the builder.
addWithPending ( Builder $builder ) : void Add the with-pending extension to the builder.
addWithPostponed ( Builder $builder ) : void Add the with-postpone extension to the builder.
addWithRejected ( Builder $builder ) : void Add the with-rejected extension to the builder.
getStatusColumn ( Builder $builder ) : string Get the "deleted at" column for the builder.
isModerationConstraint ( array $where, string $column ) : boolean Determine if the given where clause is a moderation constraint.
removeBinding ( $query, integer $key ) Remove scope constraint from the query.
removeWhere ( $query, integer $key ) Remove scope constraint from the query.

Приватные методы

Метод Описание
updateModerationStatus ( Builder $builder, $id, $status ) : boolean | integer

Описание методов

addApprove() защищенный Метод

Add the Approve extension to the builder.
protected addApprove ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addPend() защищенный Метод

Add the Postpone extension to the builder.
protected addPend ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addPending() защищенный Метод

Add the Pending extension to the builder.
protected addPending ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addPostpone() защищенный Метод

Add the Postpone extension to the builder.
protected addPostpone ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addPostponed() защищенный Метод

Add the Postponed extension to the builder.
protected addPostponed ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addReject() защищенный Метод

Add the Reject extension to the builder.
protected addReject ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addRejected() защищенный Метод

Add the Rejected extension to the builder.
protected addRejected ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addWithAnyStatus() защищенный Метод

Add the with-any-status extension to the builder.
protected addWithAnyStatus ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addWithPending() защищенный Метод

Add the with-pending extension to the builder.
protected addWithPending ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addWithPostponed() защищенный Метод

Add the with-postpone extension to the builder.
protected addWithPostponed ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

addWithRejected() защищенный Метод

Add the with-rejected extension to the builder.
protected addWithRejected ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

apply() публичный Метод

Apply the scope to a given Eloquent query builder.
public apply ( Builder $builder, Model $model ) : void
$builder Illuminate\Database\Eloquent\Builder
$model Illuminate\Database\Eloquent\Model
Результат void

extend() публичный Метод

Extend the query builder with the needed functions.
public extend ( Builder $builder ) : void
$builder Illuminate\Database\Eloquent\Builder
Результат void

getStatusColumn() защищенный Метод

Get the "deleted at" column for the builder.
protected getStatusColumn ( Builder $builder ) : string
$builder Illuminate\Database\Eloquent\Builder
Результат string

isModerationConstraint() защищенный Метод

Determine if the given where clause is a moderation constraint.
protected isModerationConstraint ( array $where, string $column ) : boolean
$where array
$column string
Результат boolean

remove() публичный Метод

(This method exists in order to achieve compatibility with laravel 5.1.*)
public remove ( Builder $builder, Model $model ) : void
$builder Illuminate\Database\Eloquent\Builder
$model Illuminate\Database\Eloquent\Model
Результат void

removeBinding() защищенный Метод

Remove scope constraint from the query.
protected removeBinding ( $query, integer $key )
$query
$key integer

removeWhere() защищенный Метод

Remove scope constraint from the query.
protected removeWhere ( $query, integer $key )
$query
$key integer

Описание свойств

$extensions защищенное свойство

All of the extensions to be added to the builder.
protected array $extensions
Результат array