kriptograf / yii2-menu
Menu module for you site
Installs: 50
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 2
Forks: 3
Open Issues: 0
Type:yii2-extension
Requires
- kartik-v/yii2-grid: @dev
- yii2tech/ar-position: ^1.0
- yiisoft/yii2: ~2.0.0
This package is auto-updated.
Last update: 2025-02-24 18:33:40 UTC
README
Menu module for you site
Installation
The preferred way to install this extension is through composer.
Either run
composer require --prefer-dist kriptograf/yii2-menu "*"
or add
"kriptograf/yii2-menu": "*"
to the require section of your composer.json
file.
Add the following code to config file Yii2
'modules' => [ 'menu' => [ 'class' => '\kriptograf\menu\Module', ], ]
Add the following code to config file Yii2 for settings module kartik-v gridview
'modules' => [ 'gridview' => [ 'class' => '\kartik\grid\Module' // enter optional module parameters below - only if you need to // use your own export download action or custom translation // message source // 'downloadAction' => 'gridview/export/download', 'i18n' => [ 'class' => 'yii\i18n\PhpMessageSource', 'basePath' => '@kvgrid/messages', 'forceTranslation' => true ] ] ];
Configuration
1. Create database schema
Make sure that you have properly configured db
application component and run the following command:
$ php yii migrate/up --migrationPath=@vendor/kriptograf/yii2-menu/migrations
2. Getting started for admin
/menu/creator
Usage
Once the extension is installed, simply use it in your code by :
<?php echo \kriptograf\menu\widgets\MenuWidget::widget(['code'=>'placement_you_code'])?>