项目作者: cadyrov

项目描述 :
高级语言: PHP
项目地址: git://github.com/cadyrov/yii2-gii.git
创建时间: 2018-12-28T14:54:49Z
项目社区:https://github.com/cadyrov/yii2-gii

开源协议:BSD 2-Clause "Simplified" License

下载


yii2-gii alternative

Installation

The preferred way to install this extension is through composer.

Either run

  1. php composer.phar require --prefer-dist cadyrov/yii2-gii "*"

or add

  1. "cadyrov/yii2-gii": "*"

to the require section of your composer.json file.

Usage

Once the extension is installed, simply use it in your web.php like this

  1. $config['modules']['gii'] = [
  2. 'class' => 'yii\gii\Module',
  3. // uncomment the following to add your IP if you are not connecting from localhost.
  4. //'allowedIPs' => ['127.0.0.1', '::1'],
  5. 'generators' => [
  6. 'crud' => [
  7. 'class' => 'cadyrov\gii\crud\Generator',
  8. 'templates' => [
  9. 'crud' => 'cadyrov/gii/crud/default',
  10. ]
  11. ],
  12. 'model' => [
  13. 'class' => 'cadyrov\gii\model\Generator',
  14. 'templates' => [
  15. 'model' => 'cadyrov/gii/model/default',
  16. ]
  17. ]
  18. ],
  19. ];

There are reserved fields on generation CRUD - deleted_at