PHP Class yii2tech\admin\actions\Callback

Since: 1.0
Author: Paul Klimov ([email protected])
Inheritance: extends Action
Show file Open project: yii2tech/admin

Public Properties

Property Type Description
$callback name of the model method, which should be invoked or callback, which should be executed for the found model. The signature of the callable should be: php function ($model) { }
$flash flash message to be set on success.

Public Methods

Method Description
run ( string $id ) : mixed Invokes configured method on the specified model.

Method Details

run() public method

Invokes configured method on the specified model.
public run ( string $id ) : mixed
$id string the primary key of the model.
return mixed response.

Property Details

$callback public property

name of the model method, which should be invoked or callback, which should be executed for the found model. The signature of the callable should be: php function ($model) { }
public $callback

$flash public property

flash message to be set on success.
See also: Action::setFlash() for details on how setup flash.
public $flash