leaps/leaps-generator

This package is abandoned and no longer maintained. No replacement package was suggested.

The Gii extension for the Leaps framework

Installs: 108

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Type:leaps-extension

1.0.4 2016-04-09 10:17 UTC

This package is not auto-updated.

Last update: 2016-08-24 04:08:29 UTC


README

这个扩展提供了一个基于网络的代码生成器到你的 Leaps framework 应用程序,You can use Generator to quickly generate models, forms, modules, CRUD, etc.

For license information check the LICENSE-file.

文档在 docs/guide/README.md.

Latest Stable Version Total Downloads Build Status

安装

推荐的安装方式是通过 composer 工具安装。

直接使用composer命令安装

php composer.phar require --dev --prefer-dist leaps/leaps-generator

或添加

"leaps/leaps-generator": "~2.0.0"

到你项目里的composer.json文件的require-dev段中。

使用

一旦安装扩展,请简单地修改您的应用程序配置如下:

return [
    'bootstrap' => ['generator'],
    'modules' => [
        'generator' => [
            'className' => 'Leaps\Generator\Module',
        ],
        // ...
    ],
    // ...
];

您可以通过以下网址访问Generator:

http://localhost/path/to/index.php?r=generator

或如果您已经启用了漂亮的网址,您可以使用以下网址:

http://localhost/path/to/index.php/generator

使用相同的配置在您的控制台应用程序,您也可以通过访问generator命令行如下,

# change path to your application's base path
cd path/to/AppBasePath

# show help information about Generator
leaps help generator

# show help information about the model generator in Generator
leaps help generator/model

# generate City model from city table
leaps generator/model --tableName=city --modelClass=City