Skip to content

otsec/yii2-fladmin

Repository files navigation

FlAdmin Extension for Yii2

Installation

The preferred way to install this extension is through composer.

{
    ...

    "require": {
        "otsec/yii2-fladmin": "0.2.*"
    },

    "repositories": [
        {
            "type": "vcs",
            "url":  "https://github.com/otsec/yii2-fladmin.git"
        }
    ],
}

CRUD Generator

if (YII_ENV_DEV) {
    // configuration adjustments for 'dev' environment
    ...

    $config['bootstrap'][] = 'gii';
    $config['modules']['gii'] = [
        'class' => 'yii\gii\Module',
        'generators' => [
            'crud' => [
                'class' => 'yii\gii\generators\crud\Generator',
                'templates' => [
                    'fladmin' => '@vendor/otsec/yii2-fladmin/generator-crud',
                ],
            ]
        ],
    ];
}