iteracode / cakephp-bake-templates-trw
更好的蛋糕烘焙生成器
1.0.0
2020-08-03 12:35 UTC
Requires
- cakephp/bake: ^1.1
- cakephp/cakephp: ^3.5
Requires (Dev)
- phpunit/phpunit: ^5.7.14|^6.0
This package is auto-updated.
Last update: 2024-09-29 05:48:53 UTC
README
此插件帮助为以下内容生成更好的bake代码:
- 实体
- 固定装置
- 模板(需要bootstrap)
- 添加
- 编辑
- 索引
此插件与bake 1.x版本兼容
https://book.cakephp.com.cn/bake/1/en/development.html#creating-a-bake-theme
如果需要在bake 2.x中使用此插件,您需要更改插件结构
https://book.cakephp.com.cn/bake/2/en/development.html#creating-a-bake-theme
安装
composer require iteracode/cakephp-bake-templates-trw
添加到Application.php
public function bootstrap() { $this->addPlugin('CsvView'); //Add here $this->addPlugin('CakephpBakeTemplatesTrw'); parent::bootstrap(); }
使用
要使用此插件进行烘焙,只需使用
bin/cake bake WHAT_TO_BAKE TABLE --theme CakephpBakeTemplatesTrw
如果您想将此主题作为默认主题使用,只需添加
<?php Configure::write('Bake.theme', 'CakephpBakeTemplatesTrw');
到config/bootstrap.php或config/bootstrap_cli.php