dev-master
9999999-dev https://github.com/trandangtri/yii2-giiallUsing Yii2-Gii to generate code for other PHP framework, such as PhalconEye, Laravel, etc.
BSD-3-Clause
The Requires
laravel yii2 gii generator phalconeye
Wallogit.com
2017 © Pedro Peláez
Using Yii2-Gii to generate code for other PHP framework, such as PhalconEye, Laravel, etc.
Using Yii2-Gii to generate code for other PHP framework, such as Phalcon, PhalconEye, Laravel, etc., (*1)
PROJECT IS IN DEVELOPMENT STAGE!, (*2)
Create a basic yii application., (*3)
php composer.phar create-project --prefer-dist --stability=dev yiisoft/yii2-app-basic /path/to/yii-application
Go to the project directory and install yii2-giiall, (*4)
cd yii-application php composer.phar require trandangtri/`yii2-giiall` @dev-master
Edit the application config..., (*5)
edit config/web.php
... and add the yii2-giiall generator in the YII_ENV_DEV section, (*6)
$config['modules']['gii'] = array();
$config['modules']['gii']['class'] = 'yii\gii\Module';
$config['modules']['gii'] = [
'class' => 'yii\gii\Module',
'allowedIPs' => ['::1', '192.168.1.*'],
'generators' => [
// ...
'phalconeye-model' => [
'class' => 'trandangtri\giiall\phalconeye\model\Generator',
'appPath' => '../../app/'
],
// ...
],
];
Remember setup the appPath to point to the application folder of your Core application. In this case, it pointed to PhalconEye application folder, (*7)
And don't forget to setup a database application component, eg., (*8)
'db' => [
'class' => 'yii\db\Connection',
'dsn' => 'mysql:host=localhost;dbname=devdb',
'username' => 'root',
'password' => 'root',
'charset' => 'utf8',
],
Open Gii..., (*9)
http://localhost/index.php?r=gii
...and select the yii2-giiall template, you may need to create some models in advance., (*10)
Using Yii2-Gii to generate code for other PHP framework, such as PhalconEye, Laravel, etc.
BSD-3-Clause
laravel yii2 gii generator phalconeye