yii\rest\ActiveController::checkAccess PHP Метод

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

This method should be overridden to check whether the current user has the privilege to run the specified action against the specified data model. If the user does not have access, a [[ForbiddenHttpException]] should be thrown.
public checkAccess ( string $action, object $model = null, array $params = [] )
$action string the ID of the action to be executed
$model object the model to be accessed. If null, it means no specific model is being accessed.
$params array additional parameters
    public function checkAccess($action, $model = null, $params = [])
    {
    }

Usage Example

Пример #1
0
 public function _checkAccess($action, $model = null, $params = array())
 {
     var_dump($action);
     var_dump($model);
     var_dump($params);
     die;
     parent::checkAccess($action, $model, $params);
 }
All Usage Examples Of yii\rest\ActiveController::checkAccess