CMYii CMS
CMYii - is CMS admin system based on Yii Framework 2., (*1)
CMYii provides only a framework for management with data, you need to implement the data blocks yourself., (*2)
This module provides the admin system itself., (*3)
Install
composer require paulzi/cmyii
Usage
Apply migrations
Apply migrations in migrations
folder. To do this, use one of the following methods:, (*4)
1) Add paulzi\cmyii\migrations
namespace to your console app:, (*5)
return [
'controllerMap' => [
'migrate' => [
'class' => 'yii\console\controllers\MigrateController',
'migrationPath' => null,
'migrationNamespaces' => [
'console\migrations',
'paulzi\cmyii\migrations',
],
],
],
]
2) Run command:, (*6)
./yii migrate --migrationPath= --migrationNamespaces=paulzi\cmyii\migrations
Specify in the configs of the application:, (*7)
return [
'bootstrap' => ['cmyii'],
'modules' => [
'cmyii' => [
'class' => 'paulzi\cmyii\Cmyii',
],
'admin' => [
'class' => 'paulzi\cmyii\admin\CmyiiAdmin',
'adminBlocks' => [
'common\cmyii\text\TextAdminWidget',
],
],
],
];
Add area in layout
Add Area widgets in your layout:, (*8)
<?= \paulzi\cmyii\widgets\Area::widget(['id' => 'main']) ?>
Configure RBAC and add admin
role., (*9)
See in example
folder for text block widget sample., (*10)
Add your first layout and site (example domains
: http?://*
)., (*11)
Include widget in adminBlocks
section of config module., (*12)
Go to admin
Follow to URL http://yourdomain/admin/
and add block on page., (*13)
Documentation
To do, (*14)