diff --git a/README.md b/README.md index 119470fa..4725edb2 100644 --- a/README.md +++ b/README.md @@ -22,13 +22,13 @@ The preferred way to install this extension is through [composer](http://getcomp Either run ``` -composer require webvimark/module-user-management +composer require vanterbit/module-user-management ``` or add ``` -"webvimark/module-user-management": "^1" +"vanterbit/module-user-management": "^1" ``` to the require section of your `composer.json` file. @@ -42,18 +42,18 @@ Configuration 'components'=>[ 'user' => [ - 'class' => 'webvimark\modules\UserManagement\components\UserConfig', + 'class' => 'vanterbit\modules\UserManagement\components\UserConfig', // Comment this if you don't want to record user logins 'on afterLogin' => function($event) { - \webvimark\modules\UserManagement\models\UserVisitLog::newVisitor($event->identity->id); + \vanterbit\modules\UserManagement\models\UserVisitLog::newVisitor($event->identity->id); } ], ], 'modules'=>[ 'user-management' => [ - 'class' => 'webvimark\modules\UserManagement\UserManagementModule', + 'class' => 'vanterbit\modules\UserManagement\UserManagementModule', // 'enableRegistration' => true, @@ -98,8 +98,8 @@ To see full list of options check *UserManagementModule* file 'modules'=>[ 'user-management' => [ - 'class' => 'webvimark\modules\UserManagement\UserManagementModule', - 'controllerNamespace'=>'vendor\webvimark\modules\UserManagement\controllers', // To prevent yii help from crashing + 'class' => 'vanterbit\modules\UserManagement\UserManagementModule', + 'controllerNamespace'=>'vendor\vanterbit\modules\UserManagement\controllers', // To prevent yii help from crashing ], ], @@ -109,7 +109,7 @@ To see full list of options check *UserManagementModule* file ```php -./yii migrate --migrationPath=vendor/webvimark/module-user-management/migrations/ +./yii migrate --migrationPath=vendor/vanterbit/module-user-management/migrations/ ``` @@ -121,7 +121,7 @@ public function behaviors() { return [ 'ghost-access'=> [ - 'class' => 'webvimark\modules\UserManagement\components\GhostAccessControl', + 'class' => 'vanterbit\modules\UserManagement\components\GhostAccessControl', ], ]; } @@ -134,8 +134,8 @@ Where you can go ```php false, @@ -233,7 +233,7 @@ Events can be handled via config file like following 'modules'=>[ 'user-management' => [ - 'class' => 'webvimark\modules\UserManagement\UserManagementModule', + 'class' => 'vanterbit\modules\UserManagement\UserManagementModule', 'on afterRegistration' => function(UserAuthEvent $event) { // Here you can do your own stuff like assign roles, send emails and so on }, @@ -249,7 +249,7 @@ FAQ **Question**: Do you have API docs? -**Answer**: Check this one http://opensource.id5.com.br/webvimark/doc/index.html (Credits to [lukBarros](https://github.com/lukBarros)) +**Answer**: Check this one http://opensource.id5.com.br/vanterbit/doc/index.html (Credits to [lukBarros](https://github.com/lukBarros)) **Question**: I want users to register and login with they e-mails! Mmmmm... And they should confirm it too! @@ -257,7 +257,7 @@ FAQ **Question**: I want to have profile for user with avatar, birthday and stuff. What should I do ? -**Answer**: Profiles are to project-specific, so you'll have to implement them yourself (but you can find example here - https://github.com/webvimark/user-management/wiki/Profile-and-custom-registration). Here is how to do it without modifying this module +**Answer**: Profiles are to project-specific, so you'll have to implement them yourself (but you can find example here - https://github.com/vanterbit/user-management/wiki/Profile-and-custom-registration). Here is how to do it without modifying this module 1) Create table and model for profile, that have user_id (connect with "user" table) diff --git a/UserManagementModule.php b/UserManagementModule.php index 75717919..13fbf474 100644 --- a/UserManagementModule.php +++ b/UserManagementModule.php @@ -1,6 +1,6 @@ i18n->translations['modules/user-management/*'] = [ 'class' => 'yii\i18n\PhpMessageSource', 'sourceLanguage' => 'en', - 'basePath' => '@vendor/webvimark/module-user-management/messages', + 'basePath' => '@vendor/vanterbit/module-user-management/messages', 'fileMap' => [ 'modules/user-management/back' => 'back.php', 'modules/user-management/front' => 'front.php', diff --git a/components/AbstractItemEvent.php b/components/AbstractItemEvent.php index d5afecf1..63d9eb87 100644 --- a/components/AbstractItemEvent.php +++ b/components/AbstractItemEvent.php @@ -1,5 +1,5 @@ ['xvetx\modules\UserManagement\components\AuthHelper', 'layoutHandler'], + * 'on beforeAction'=>['vanterbit\modules\UserManagement\components\AuthHelper', 'layoutHandler'], * * @param \yii\base\ActionEvent $event */ diff --git a/components/GhostAccessControl.php b/components/GhostAccessControl.php index fd7d7e5b..cfc1828a 100644 --- a/components/GhostAccessControl.php +++ b/components/GhostAccessControl.php @@ -1,9 +1,9 @@ User::canRoute($item['url') will be added * - * @package webvimark\modules\UserManagement\components + * @package vanterbit\modules\UserManagement\components */ class GhostMenu extends Menu { diff --git a/components/GhostNav.php b/components/GhostNav.php index 2417705e..d95ce1bd 100644 --- a/components/GhostNav.php +++ b/components/GhostNav.php @@ -1,7 +1,7 @@ User::canRoute($item['url') will be added * - * @package webvimark\modules\UserManagement\components + * @package vanterbit\modules\UserManagement\components */ class GhostNav extends Nav { diff --git a/components/UserAuthEvent.php b/components/UserAuthEvent.php index c713a20e..5a285f91 100644 --- a/components/UserAuthEvent.php +++ b/components/UserAuthEvent.php @@ -1,10 +1,10 @@ 'webvimark\modules\UserManagement\models\User', + 'targetClass' => 'vanterbit\modules\UserManagement\models\User', 'targetAttribute' => 'username', ], diff --git a/models/rbacDB/AbstractItem.php b/models/rbacDB/AbstractItem.php index fae8ae59..950c68dd 100644 --- a/models/rbacDB/AbstractItem.php +++ b/models/rbacDB/AbstractItem.php @@ -1,9 +1,9 @@ diff --git a/views/auth-item-group/create.php b/views/auth-item-group/create.php index f1214c58..8c21c1b6 100644 --- a/views/auth-item-group/create.php +++ b/views/auth-item-group/create.php @@ -1,11 +1,11 @@ title = UserManagementModule::t('back', 'Creating permission group'); diff --git a/views/auth-item-group/index.php b/views/auth-item-group/index.php index 51a37134..331af48f 100644 --- a/views/auth-item-group/index.php +++ b/views/auth-item-group/index.php @@ -1,19 +1,19 @@ title = UserManagementModule::t('back', 'Permission groups'); diff --git a/views/auth-item-group/update.php b/views/auth-item-group/update.php index 1d3520c7..09f9d50c 100644 --- a/views/auth-item-group/update.php +++ b/views/auth-item-group/update.php @@ -1,11 +1,11 @@ title = UserManagementModule::t('back', 'Editing permission group') . ': ' . $model->name; diff --git a/views/auth-item-group/view.php b/views/auth-item-group/view.php index b3b289a3..2e8bb693 100644 --- a/views/auth-item-group/view.php +++ b/views/auth-item-group/view.php @@ -1,12 +1,12 @@ title = $model->name; diff --git a/views/auth/changeOwnPassword.php b/views/auth/changeOwnPassword.php index 9985fec8..fe22dfdd 100644 --- a/views/auth/changeOwnPassword.php +++ b/views/auth/changeOwnPassword.php @@ -1,12 +1,12 @@ title = UserManagementModule::t('back', 'Change own password'); diff --git a/views/auth/changeOwnPasswordSuccess.php b/views/auth/changeOwnPasswordSuccess.php index 88e0a4f9..49f6ae79 100644 --- a/views/auth/changeOwnPasswordSuccess.php +++ b/views/auth/changeOwnPasswordSuccess.php @@ -1,6 +1,6 @@ title = UserManagementModule::t('front', 'Confirm E-mail'); diff --git a/views/auth/confirmEmailSuccess.php b/views/auth/confirmEmailSuccess.php index 7bd4c0e7..8a0c822a 100644 --- a/views/auth/confirmEmailSuccess.php +++ b/views/auth/confirmEmailSuccess.php @@ -1,11 +1,11 @@ title = UserManagementModule::t('front', 'E-mail confirmed'); diff --git a/views/auth/login.php b/views/auth/login.php index 25d7b088..a851d625 100644 --- a/views/auth/login.php +++ b/views/auth/login.php @@ -1,11 +1,11 @@ diff --git a/views/auth/passwordRecovery.php b/views/auth/passwordRecovery.php index b834c6d0..343d8240 100644 --- a/views/auth/passwordRecovery.php +++ b/views/auth/passwordRecovery.php @@ -1,13 +1,13 @@ title = UserManagementModule::t('front', 'Password recovery'); diff --git a/views/auth/passwordRecoverySuccess.php b/views/auth/passwordRecoverySuccess.php index bc7b678f..058615c4 100644 --- a/views/auth/passwordRecoverySuccess.php +++ b/views/auth/passwordRecoverySuccess.php @@ -1,6 +1,6 @@ title = UserManagementModule::t('front', 'Registration'); diff --git a/views/auth/registrationWaitForEmailConfirmation.php b/views/auth/registrationWaitForEmailConfirmation.php index 05805288..8bf7e6f9 100644 --- a/views/auth/registrationWaitForEmailConfirmation.php +++ b/views/auth/registrationWaitForEmailConfirmation.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('front', 'Registration - confirm your e-mail'); diff --git a/views/layouts/loginLayout.php b/views/layouts/loginLayout.php index a728287d..e5fba485 100644 --- a/views/layouts/loginLayout.php +++ b/views/layouts/loginLayout.php @@ -1,6 +1,6 @@ title = UserManagementModule::t('back', 'Permission creation'); $this->params['breadcrumbs'][] = ['label' => UserManagementModule::t('back', 'Permissions'), 'url' => ['index']]; diff --git a/views/permission/index.php b/views/permission/index.php index 4f8796a2..77eba5af 100644 --- a/views/permission/index.php +++ b/views/permission/index.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('back', 'Permissions'); diff --git a/views/permission/update.php b/views/permission/update.php index b2736079..92f777af 100644 --- a/views/permission/update.php +++ b/views/permission/update.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('back', 'Editing permission: ') . ' ' . $model->name; $this->params['breadcrumbs'][] = ['label' => UserManagementModule::t('back', 'Permissions'), 'url' => ['index']]; diff --git a/views/permission/view.php b/views/permission/view.php index a28af200..97b12252 100644 --- a/views/permission/view.php +++ b/views/permission/view.php @@ -9,8 +9,8 @@ * @var yii\rbac\Permission $item */ -use webvimark\modules\UserManagement\components\GhostHtml; -use webvimark\modules\UserManagement\UserManagementModule; +use vanterbit\modules\UserManagement\components\GhostHtml; +use vanterbit\modules\UserManagement\UserManagementModule; use yii\helpers\ArrayHelper; use yii\helpers\Html; diff --git a/views/role/_form.php b/views/role/_form.php index 764e92ff..66c32399 100644 --- a/views/role/_form.php +++ b/views/role/_form.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('back', 'Role creation'); $this->params['breadcrumbs'][] = ['label' => UserManagementModule::t('back', 'Roles'), 'url' => ['index']]; diff --git a/views/role/index.php b/views/role/index.php index 6d09e1b3..c1c391ac 100644 --- a/views/role/index.php +++ b/views/role/index.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('back', 'Roles'); diff --git a/views/role/update.php b/views/role/update.php index 8c28b7b1..4dbbf01d 100644 --- a/views/role/update.php +++ b/views/role/update.php @@ -1,10 +1,10 @@ title = UserManagementModule::t('back', 'Editing role: ') . ' ' . $model->name; $this->params['breadcrumbs'][] = ['label' => UserManagementModule::t('back', 'Roles'), 'url' => ['index']]; diff --git a/views/role/view.php b/views/role/view.php index 2754628e..dc614563 100644 --- a/views/role/view.php +++ b/views/role/view.php @@ -10,9 +10,9 @@ * @var yii\rbac\Role $role */ -use webvimark\modules\UserManagement\components\GhostHtml; -use webvimark\modules\UserManagement\models\rbacDB\Role; -use webvimark\modules\UserManagement\UserManagementModule; +use vanterbit\modules\UserManagement\components\GhostHtml; +use vanterbit\modules\UserManagement\models\rbacDB\Role; +use vanterbit\modules\UserManagement\UserManagementModule; use yii\helpers\ArrayHelper; use yii\helpers\Html; diff --git a/views/user-permission/set.php b/views/user-permission/set.php index 462a72d2..7ee19c6b 100644 --- a/views/user-permission/set.php +++ b/views/user-permission/set.php @@ -2,12 +2,12 @@ /** * @var yii\web\View $this * @var array $permissionsByGroup - * @var webvimark\modules\UserManagement\models\User $user + * @var vanterbit\modules\UserManagement\models\User $user */ -use webvimark\modules\UserManagement\components\GhostHtml; -use webvimark\modules\UserManagement\models\rbacDB\Role; -use webvimark\modules\UserManagement\UserManagementModule; +use vanterbit\modules\UserManagement\components\GhostHtml; +use vanterbit\modules\UserManagement\models\rbacDB\Role; +use vanterbit\modules\UserManagement\UserManagementModule; use yii\bootstrap\BootstrapPluginAsset; use yii\helpers\ArrayHelper; use yii\helpers\Html; diff --git a/views/user-visit-log/index.php b/views/user-visit-log/index.php index 4d70a702..2726214f 100644 --- a/views/user-visit-log/index.php +++ b/views/user-visit-log/index.php @@ -1,16 +1,16 @@ title = UserManagementModule::t('back', 'Visit log'); diff --git a/views/user-visit-log/view.php b/views/user-visit-log/view.php index ce7a0731..acdd2085 100644 --- a/views/user-visit-log/view.php +++ b/views/user-visit-log/view.php @@ -1,12 +1,12 @@ title = $model->id; diff --git a/views/user/_form.php b/views/user/_form.php index e828d60f..a239a8fc 100644 --- a/views/user/_form.php +++ b/views/user/_form.php @@ -1,14 +1,14 @@ diff --git a/views/user/_search.php b/views/user/_search.php index d5f0c455..d88f021e 100644 --- a/views/user/_search.php +++ b/views/user/_search.php @@ -5,7 +5,7 @@ /** * @var yii\web\View $this - * @var webvimark\modules\UserManagement\models\search\UserSearch $model + * @var vanterbit\modules\UserManagement\models\search\UserSearch $model * @var yii\widgets\ActiveForm $form */ ?> diff --git a/views/user/changePassword.php b/views/user/changePassword.php index 1ec181c0..3d040204 100644 --- a/views/user/changePassword.php +++ b/views/user/changePassword.php @@ -1,12 +1,12 @@ title = UserManagementModule::t('back', 'Changing password for user: ') . ' ' . $model->username; diff --git a/views/user/create.php b/views/user/create.php index f890c518..fbe34ee2 100644 --- a/views/user/create.php +++ b/views/user/create.php @@ -1,11 +1,11 @@ title = UserManagementModule::t('back', 'User creation'); diff --git a/views/user/index.php b/views/user/index.php index 2c5a6565..4301577d 100644 --- a/views/user/index.php +++ b/views/user/index.php @@ -1,21 +1,21 @@ title = UserManagementModule::t('back', 'Users'); @@ -73,7 +73,7 @@ ['class' => 'yii\grid\SerialColumn', 'options'=>['style'=>'width:10px'] ], [ - 'class'=>'webvimark\components\StatusColumn', + 'class'=>'vanterbit\components\StatusColumn', 'attribute'=>'superadmin', 'visible'=>Yii::$app->user->isSuperadmin, ], @@ -91,7 +91,7 @@ 'visible'=>User::hasPermission('viewUserEmail'), ], [ - 'class'=>'webvimark\components\StatusColumn', + 'class'=>'vanterbit\components\StatusColumn', 'attribute'=>'email_confirmed', 'visible'=>User::hasPermission('viewUserEmail'), ], @@ -138,7 +138,7 @@ ], ], [ - 'class'=>'webvimark\components\StatusColumn', + 'class'=>'vanterbit\components\StatusColumn', 'attribute'=>'status', 'optionsArray'=>[ [User::STATUS_ACTIVE, UserManagementModule::t('back', 'Active'), 'success'], diff --git a/views/user/update.php b/views/user/update.php index 0a4ef0a1..a3cd8829 100644 --- a/views/user/update.php +++ b/views/user/update.php @@ -1,14 +1,14 @@ title = UserManagementModule::t('back', 'Editing user: ') . ' ' . $model->username; diff --git a/views/user/view.php b/views/user/view.php index 5623a29b..5ff1285c 100644 --- a/views/user/view.php +++ b/views/user/view.php @@ -1,16 +1,16 @@ title = $model->username;