new-support.webeffector.ru/backend/modules/user/README.md

63 lines
1.5 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Модуль User
## Подключение модуля
'modules' => [
'user' => [
'class' => backend\modules\user\Module::class,
],
]
Прописываем nameSpace в сгенерированном файле для подключения к проекту
namespace backend\modules\user\migrations;
Добавляем миграции в настройки проекта
'controllerMap' => [
'migrate' => [
'class' => yii\console\controllers\MigrateController::class,
'migrationNamespaces' => [
'backend\modules\user\migrations',
],
],
],
docker-compose run --rm php ./yii migrate --migrationPath=@yii/rbac/migrations
docker-compose run --rm php ./yii migrate
Добавление миграций
docker-compose run --rm php ./yii migrate/create --migrationPath=@backend/modules/user/migrations create_users_table
##Roles
user_customer:
- customer (заказчик);
user_employee:
- author (автор/исполнитель);
- technic (ТЗ-мейкер);
- auditor (аудитор);
- manager (контент-менеджер);
user_admin:
- supervisor (супервайзер);
- admin (администратор);
test data:
- admin@content.local:admin
- supervisor@content.local:supervisor
- customer@content.local:customer
- technic@content.local:technic
- author@content.local:author
- auditor@content.local:auditor
- manager@content.local:manager