uraankhayayaal / yii2-page
Page module for Yii2 with slug
Installs: 262
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 1
Open Issues: 0
Type:yii2-extension
Requires
- kartik-v/yii2-widget-colorinput: ^1.0.6
- phpnt/yii2-chartjs: *
- uraankhayayaal/yii2-materializecomponents: ~1.0.1
- uraankhayayaal/yii2-redactor: ~1.0.0
- uraankhayayaal/yii2-sortable: ~1.0.1
- yiisoft/yii2: ~2.0.0
- yiisoft/yii2-bootstrap4: ^2.0.8
This package is auto-updated.
Last update: 2024-11-12 08:59:06 UTC
README
Page module for Yii2 with slug
Installation
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist uraankhayayaal/yii2-page "*"
or add
"uraankhayayaal/yii2-page": "*"
to the require section of your composer.json
file.
Usage
Once the extension is installed, simply add in your console config:
'controllerMap' => [ ... 'migrate' => [ ... 'migrationPath' => [ ... '@uraankhayayaal/page/src/migrations', ... ], ], ],
And just run the command:
php yii migrate
Set in common config params:
return [ /* ... */ 'domain' => 'https://yourdomain.example', ];
Add urls in your backend project:
Url::toRoute('/page/back/index');
Add RBAC roles:
page
Custom view file:
'custom_view_for_modules' => [ 'page_front' => [ 'view' => '@frontend/views/front_page/view', ], ],
Add fixtures:
php yii fixture PageMenuItem --namespace='uraankhayayaal\page\tests\fixtures'
php yii fixture PageBlockChart --namespace='uraankhayayaal\page\tests\fixtures'
php yii fixture PageBlock --namespace='uraankhayayaal\page\tests\fixtures'
Add fixtures in docker:
php yii fixture PageMenuItem --namespace='uraankhayayaal\page\tests\fixtures' --interactive=0
php yii fixture PageBlockChart --namespace='uraankhayayaal\page\tests\fixtures' --interactive=0
php yii fixture PageBlock --namespace='uraankhayayaal\page\tests\fixtures' --interactive=0