PHP Class Xpressengine\Menu\Models\MenuItem

Author: XE Developers ([email protected])
Inheritance: extends Xpressengine\Category\Models\CategoryItem
Mostra file Open project: xpressengine/xpressengine Class Usage Examples

Public Properties

Property Type Description
$incrementing boolean Indicates if the IDs are auto-incrementing.
$timestamps boolean Indicates if the model should be timestamped.

Protected Properties

Property Type Description
$casts array The attributes that should be cast to native types.
$closureTable string The hierarchy table associated with the model.
$fillable array The attributes that are mass assignable.
$linkResolver Closure
$selected boolean Indicates if the model selected.
$table string The table associated with the model.

Public Methods

Method Description
basicImage ( ) : BelongsTo Basic link image relationship
getAggregatorKeyName ( ) : string Get the aggregator key name for model
getAggregatorModel ( ) : string Get the aggregator model name for model
getChildren ( ) : Illuminate\Database\Eloquent\Collection Get a children collection of model
getHoverImage ( ) : Image | null Get hover link image of model
getLinkAttribute ( ) : string Get link attribute
getMBasicImage ( ) : Image | null Get mobile basic link image of model
getMHoverImage ( ) : Image | null Get mobile hover link image of model
getMSelectedImage ( ) : Image | null Get mobile selected link image of model
getSelectedImage ( ) : Image | null Get selected link image of model
hoverImage ( ) : BelongsTo Hover link image relationship
isSelected ( ) : boolean Determine if model is selected
mBasicImage ( ) : BelongsTo Mobile basic link image relationship
mHoverImage ( ) : BelongsTo Mobile hover link image relationship
mSelectedImage ( ) : BelongsTo Mobile selected link image relationship
menu ( ) : BelongsTo Alias aggregator
route ( ) : Illuminate\Database\Eloquent\Relations\HasOne Instance route relationship
selectedImage ( ) : BelongsTo Selected link image relationship
setLinkResolver ( Closure $callback ) : void Set the link resolver callback
setSelected ( boolean $bool = true ) : void Set model selected
toArray ( ) : array Convert the model instance to an array.

Method Details

basicImage() public method

Basic link image relationship
public basicImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

getAggregatorKeyName() public method

Get the aggregator key name for model
public getAggregatorKeyName ( ) : string
return string

getAggregatorModel() public method

Get the aggregator model name for model
public getAggregatorModel ( ) : string
return string

getChildren() public method

Get a children collection of model
public getChildren ( ) : Illuminate\Database\Eloquent\Collection
return Illuminate\Database\Eloquent\Collection

getHoverImage() public method

Get hover link image of model
public getHoverImage ( ) : Image | null
return Xpressengine\Media\Models\Image | null

getLinkAttribute() public method

Get link attribute
public getLinkAttribute ( ) : string
return string

getMBasicImage() public method

Get mobile basic link image of model
public getMBasicImage ( ) : Image | null
return Xpressengine\Media\Models\Image | null

getMHoverImage() public method

Get mobile hover link image of model
public getMHoverImage ( ) : Image | null
return Xpressengine\Media\Models\Image | null

getMSelectedImage() public method

Get mobile selected link image of model
public getMSelectedImage ( ) : Image | null
return Xpressengine\Media\Models\Image | null

getSelectedImage() public method

Get selected link image of model
public getSelectedImage ( ) : Image | null
return Xpressengine\Media\Models\Image | null

hoverImage() public method

Hover link image relationship
public hoverImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

isSelected() public method

Determine if model is selected
public isSelected ( ) : boolean
return boolean

mBasicImage() public method

Mobile basic link image relationship
public mBasicImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

mHoverImage() public method

Mobile hover link image relationship
public mHoverImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

mSelectedImage() public method

Mobile selected link image relationship
public mSelectedImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

menu() public method

Alias aggregator
public menu ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

route() public method

Instance route relationship
public route ( ) : Illuminate\Database\Eloquent\Relations\HasOne
return Illuminate\Database\Eloquent\Relations\HasOne

selectedImage() public method

Selected link image relationship
public selectedImage ( ) : BelongsTo
return Illuminate\Database\Eloquent\Relations\BelongsTo

setLinkResolver() public static method

Set the link resolver callback
public static setLinkResolver ( Closure $callback ) : void
$callback Closure resolver callback
return void

setSelected() public method

Set model selected
public setSelected ( boolean $bool = true ) : void
$bool boolean boolean value
return void

toArray() public method

Convert the model instance to an array.
public toArray ( ) : array
return array

Property Details

$casts protected_oe property

The attributes that should be cast to native types.
protected array $casts
return array

$closureTable protected_oe property

The hierarchy table associated with the model.
protected string $closureTable
return string

$fillable protected_oe property

The attributes that are mass assignable.
protected array $fillable
return array

$incrementing public_oe property

Indicates if the IDs are auto-incrementing.
public bool $incrementing
return boolean

$linkResolver protected_oe static_oe property

protected static Closure $linkResolver
return Closure

$selected protected_oe property

Indicates if the model selected.
protected bool $selected
return boolean

$table protected_oe property

The table associated with the model.
protected string $table
return string

$timestamps public_oe property

Indicates if the model should be timestamped.
public bool $timestamps
return boolean