Class dektrium\user\controllers\AdminController

Inheritancedektrium\user\controllers\AdminController » yii\web\Controller
Uses Traitsdektrium\user\traits\EventTrait

AdminController allows you to administrate users.

Constants

Hide inherited constants

ConstantValueDescriptionDefined By
EVENT_AFTER_BLOCK 'afterBlock' Event is triggered after blocking existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_CONFIRM 'afterConfirm' Event is triggered after confirming existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_CREATE 'afterCreate' Event is triggered after creating new user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_DELETE 'afterDelete' Event is triggered after deleting existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_PROFILE_UPDATE 'afterProfileUpdate' Event is triggered after updating existing user's profile. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_UNBLOCK 'afterUnblock' Event is triggered after unblocking existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_AFTER_UPDATE 'afterUpdate' Event is triggered after updating existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_BLOCK 'beforeBlock' Event is triggered before blocking existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_CONFIRM 'beforeConfirm' Event is triggered before confirming existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_CREATE 'beforeCreate' Event is triggered before creating new user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_DELETE 'beforeDelete' Event is triggered before deleting existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_PROFILE_UPDATE 'beforeProfileUpdate' Event is triggered before updating existing user's profile. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_UNBLOCK 'beforeUnblock' Event is triggered before unblocking existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController
EVENT_BEFORE_UPDATE 'beforeUpdate' Event is triggered before updating existing user. Triggered with \dektrium\user\events\UserEvent. dektrium\user\controllers\AdminController

Property Details

$finder protected property
protected dektrium\user\Finder $finder null

Method Details

__construct() public method

public void __construct ( $id, $module, dektrium\user\Finder $finder, $config = [] )
$id string
$module \yii\base\Module
$finder dektrium\user\Finder
$config array
actionAssignments() public method

If "dektrium/yii2-rbac" extension is installed, this page displays form where user can assign multiple auth items to user.

public string actionAssignments ( $id )
$id int
throws \yii\web\NotFoundHttpException
actionBlock() public method

Blocks the user.

public \yii\web\Response actionBlock ( $id )
$id int
actionConfirm() public method

Confirms the User.

public \yii\web\Response actionConfirm ( $id )
$id int
actionCreate() public method

Creates a new User model.

If creation is successful, the browser will be redirected to the 'index' page.

public mixed actionCreate ( )
actionDelete() public method

Deletes an existing User model.

If deletion is successful, the browser will be redirected to the 'index' page.

public mixed actionDelete ( $id )
$id int
actionIndex() public method

Lists all User models.

public mixed actionIndex ( )
actionInfo() public method

Shows information about user.

public string actionInfo ( $id )
$id int
actionUpdate() public method

Updates an existing User model.

public mixed actionUpdate ( $id )
$id int
actionUpdateProfile() public method

Updates an existing profile.

public mixed actionUpdateProfile ( $id )
$id int
behaviors() public method

public void behaviors ( )
findModel() protected method

Finds the User model based on its primary key value.

If the model is not found, a 404 HTTP exception will be thrown.

protected dektrium\user\models\User findModel ( $id )
$id int
return dektrium\user\models\User

The loaded model

throws \yii\web\NotFoundHttpException

if the model cannot be found

performAjaxValidation() protected method

Performs AJAX validation.

protected void performAjaxValidation ( $model )
$model array|\yii\base\Model
throws \yii\base\ExitException