Skip to content

AdminLTE 3 template based on Bootstrap 4 for Yii2 framework

Notifications You must be signed in to change notification settings

yii2cmf/yii2-adminlte-asset

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

starter_page

AdminLTE 3 - Free admin dashboard template based on Bootstrap 4 for Yii2 framework

AdminLTE is a fully responsive administration template. Based on Bootstrap 4 framework. Highly customizable and easy to use. Fits many screen resolutions from small mobile devices to large desktops.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require yii2cmf/yii2-adminlte-asset:0.2

or add

"yii2cmf/yii2-adminlte-asset": "~0.2"

to the require section of your composer.json file.

Configuration for module

After creating the module (e.g. admin) you should add some initialization code in the Module.php:

use Yii;
use yii\base\Theme;
use yii\base\Application;

    public function init():void
    {
        parent::init();
        $this->initTheme();
    }


    private function initTheme(): void
    {
        Yii::$app->view->theme = new Theme([
            'pathMap' => ['@app/views' => '@yii2cmf/templates/adminlte/views'],
            'baseUrl' => '@web/templates/adminlte'
        ]);
    }

Configuration for ability editing template

Copy vendor/yii2cmf/yii2-adminlte-asset/src/views/adminlte folder to app/modules/admin/views. And edit Module.php file:

use Yii;
use yii\base\Theme;
use yii\base\Application;


    public function init():void
    {
        parent::init();
        $this->initTheme();
    }

    private function initTheme(): void
    {
        Yii::$app->view->theme = new Theme([
            'pathMap' => ['@app/views' => '@app/modules/admin/views/adminlte'],
            'baseUrl' => '@web/modules/admin'
        ]);
    }
    

About

AdminLTE 3 template based on Bootstrap 4 for Yii2 framework

Resources

Stars

Watchers

Forks

Packages

No packages published