LocationScope
extends BaseScope
in package
Class LocationScope.
Table of Contents
Constants
- DEFAULT_COUNTRY_FIELD = 'country_iso'
Properties
- $city : string|null
- $cityField : string|null
- $country : string|null
- $countryField : string|null
- $state : string|null
- $stateField : string|null
- $table : string|null
Methods
- apply() : mixed
- applyQueryBuilder() : void
- getCity() : string|null
- getCityField() : string|null
- getCountry() : string|null
- getCountryField() : string|null
- getState() : string|null
- getStateField() : string|null
- getTable() : string|null
- likeOperator() : string
- return the case-insensitive LIKE operator bases on the current database driver.
- setCity() : void
- setCityField() : void
- setCountry() : $this
- setCountryField() : $this
- setState() : void
- setStateField() : void
- setTable() : $this
- alias() : string
- buildCityCondition() : mixed
- buildCountryCondition() : mixed
- buildStateCondition() : mixed
Constants
DEFAULT_COUNTRY_FIELD
public
mixed
DEFAULT_COUNTRY_FIELD
= 'country_iso'
Properties
$city
protected
string|null
$city
= null
$cityField
protected
string|null
$cityField
= null
$country
protected
string|null
$country
= null
$countryField
protected
string|null
$countryField
= null
$state
protected
string|null
$state
= null
$stateField
protected
string|null
$stateField
= null
$table
protected
string|null
$table
= null
Methods
apply()
public
apply(Builder $builder, Model $model) : mixed
Parameters
- $builder : Builder
- $model : Model
Tags
applyQueryBuilder()
public
applyQueryBuilder(Builder $builder) : void
Parameters
- $builder : Builder
getCity()
public
getCity() : string|null
Return values
string|nullgetCityField()
public
getCityField() : string|null
Return values
string|nullgetCountry()
public
getCountry() : string|null
Return values
string|nullgetCountryField()
public
getCountryField() : string|null
Return values
string|nullgetState()
public
getState() : string|null
Return values
string|nullgetStateField()
public
getStateField() : string|null
Return values
string|nullgetTable()
public
getTable() : string|null
Return values
string|nulllikeOperator()
return the case-insensitive LIKE operator bases on the current database driver.
public
likeOperator() : string
Return values
stringsetCity()
public
setCity(string|null $city) : void
Parameters
- $city : string|null
setCityField()
public
setCityField(string|null $cityField) : void
Parameters
- $cityField : string|null
setCountry()
public
setCountry(string|null $country) : $this
Parameters
- $country : string|null
Return values
$thissetCountryField()
public
setCountryField(string|null $field) : $this
Parameters
- $field : string|null
Return values
$thissetState()
public
setState(string|null $state) : void
Parameters
- $state : string|null
setStateField()
public
setStateField(string|null $stateField) : void
Parameters
- $stateField : string|null
setTable()
public
setTable(string $table) : $this
Parameters
- $table : string
Return values
$thisalias()
protected
alias(string $table, string $column) : string
Parameters
- $table : string
- $column : string
Return values
stringbuildCityCondition()
protected
buildCityCondition(Builder $builder, string $table) : mixed
Parameters
- $builder : Builder
- $table : string
buildCountryCondition()
protected
buildCountryCondition(Builder $builder, string $table) : mixed
Parameters
- $builder : Builder
- $table : string
buildStateCondition()
protected
buildStateCondition(Builder $builder, string $table) : mixed
Parameters
- $builder : Builder
- $table : string