Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jakharbek/jakharbek-menu-yii2
Menu Yii2
https://github.com/jakharbek/jakharbek-menu-yii2
Last synced: 23 days ago
JSON representation
Menu Yii2
- Host: GitHub
- URL: https://github.com/jakharbek/jakharbek-menu-yii2
- Owner: jakharbek
- Created: 2017-11-23T14:36:02.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2017-12-04T16:51:37.000Z (about 7 years ago)
- Last Synced: 2024-11-26T03:24:13.380Z (about 1 month ago)
- Language: PHP
- Size: 26.4 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Menu
====
Menu yii2Installation
------------The preferred way to install this extension is through [composer](http://getcomposer.org/download/).
Either run
```
php composer.phar require --prefer-dist jakharbek/jakharbek-menu "*"
```or add
```
"jakharbek/jakharbek-menu": "*"
```to the require section of your `composer.json` file.
Usage
-----Once the extension is installed, simply use it in your code by :
You must migrate the database from the / migration folder
Once the extension is installed, you mast configurate extension; To do this, you need to open the src/bootstrap.php:
You need to register the module in the system
for register module in system 'moduleName';
for register module in module parentModuleName/moduleName;
public static $modules = ['test/menu' => 'jakharbek\menu\modules\menu\Module'];
You need to install the download folder
self::$upload_folder = Yii::getAlias("@webroot")."/uploads/menu/";
self::$upload_folder_source = Yii::getAlias("@web")."/uploads/menu/";You need to provide links to pages:
public static $pages = [
'search' => '/test/menu/menu/search',
'manager' => '/test/menu/menu/manager',
'delete' => '/test/menu/menu/delete'
];
To indicate its permission to access the admin to change:
public static $premission_admin_panel = "controlPanel";For layout of the menu for your site, you need to inherit the ManuRender class and implement its methods and call where you want to map the example menu to the MenoTop classes located in the folders components