re #22 added impersonation

This commit is contained in:
Antonio Ramirez
2017-07-18 23:47:23 +02:00
parent 2301ccfe45
commit d3b4161f7c
6 changed files with 122 additions and 5 deletions

View File

@ -31,6 +31,10 @@ class Module extends BaseModule
* @var bool whether to display flash messages or not
*/
public $enableFlashMessages = true;
/**
* @var bool whether to be able to, as an admin, impersonate other users
*/
public $enableSwitchIdentities = true;
/**
* @var bool whether to generate passwords automatically and remove the password field from the registration form
*/
@ -92,7 +96,6 @@ class Module extends BaseModule
* @see Bootstrap::buildClassMap() for more details
*/
public $classMap = [];
/**
* @var array the url rules (routes)
*/
@ -102,12 +105,14 @@ class Module extends BaseModule
'<action:(register|resend)>' => 'registration/<action>',
'confirm/<id:\d+>/<code:[A-Za-z0-9_-]+>' => 'registration/confirm',
'forgot' => 'recovery/request',
'recover/<id:\d+>/<code:[A-Za-z0-9_-]+>' => 'recovery/reset',
'settings/<action:\w+>' => 'settings/<action>',
'recover/<id:\d+>/<code:[A-Za-z0-9_-]+>' => 'recovery/reset'
];
/**
* @var string
*/
public $viewPath = '@Da/User/resources/views';
/**
* @var string the session key name to impersonate users
*/
public $switchIdentitySessionKey = 'yuik_user';
}