trait HasTools

Traits

Trait HasQuickSearch.

Properties

static string $searchKey from  HasQuickSearch
$search from  HasQuickSearch
Collection $columns from  HasQuickSearch
Tools $tools

Header tools.

Methods

quickSearch($search = null)

No description

mixed|void
applyQuickSearch()

Apply the search query to the query.

addWhereBindings(string $query)

Add where bindings.

array
parseQueryBindings(array $queries)

Parse quick query bindings.

addWhereLikeBinding(string $column, bool $or, string $pattern)

Add where like binding to model query.

addWhereDatetimeBinding(string $column, bool $or, string $function, string $value)

Add where date time function binding to model query.

addWhereInBinding(string $column, bool $or, bool $not, string $values)

Add where in binding to the model query.

addWhereBetweenBinding(string $column, bool $or, string $start, string $end)

Add where between binding to the model query.

addWhereBasicBinding(string $column, bool $or, string $operator, string $value)

Add where basic binding to the model query.

void
tools(Closure $callback)

Setup grid tools.

string
renderHeaderTools()

Render custom tools.

initTools(Grid $grid)

Setup grid tools.

Details

in HasQuickSearch at line 35
QuickSearch quickSearch($search = null)

No description

Parameters

$search

Return Value

QuickSearch

in HasQuickSearch at line 54
protected mixed|void applyQuickSearch()

Apply the search query to the query.

Return Value

mixed|void

in HasQuickSearch at line 83
protected addWhereBindings(string $query)

Add where bindings.

Parameters

string $query

in HasQuickSearch at line 127
protected array parseQueryBindings(array $queries)

Parse quick query bindings.

Parameters

array $queries

Return Value

array

in HasQuickSearch at line 165
protected addWhereLikeBinding(string $column, bool $or, string $pattern)

Add where like binding to model query.

Parameters

string $column
bool $or
string $pattern

in HasQuickSearch at line 183
protected addWhereDatetimeBinding(string $column, bool $or, string $function, string $value)

Add where date time function binding to model query.

Parameters

string $column
bool $or
string $function
string $value

in HasQuickSearch at line 198
protected addWhereInBinding(string $column, bool $or, bool $not, string $values)

Add where in binding to the model query.

Parameters

string $column
bool $or
bool $not
string $values

in HasQuickSearch at line 223
protected addWhereBetweenBinding(string $column, bool $or, string $start, string $end)

Add where between binding to the model query.

Parameters

string $column
bool $or
string $start
string $end

in HasQuickSearch at line 238
protected addWhereBasicBinding(string $column, bool $or, string $operator, string $value)

Add where basic binding to the model query.

Parameters

string $column
bool $or
string $operator
string $value

at line 27
void tools(Closure $callback)

Setup grid tools.

Parameters

Closure $callback

Return Value

void

at line 37
string renderHeaderTools()

Render custom tools.

Return Value

string

at line 48
protected HasTools initTools(Grid $grid)

Setup grid tools.

Parameters

Grid $grid

Return Value

HasTools