perrin / crud-fast
用于在 Laravel 中生成 CRUD 操作的包。
dev-main
2024-05-13 16:55 UTC
Requires
- php: ^8.0
- illuminate/support: ^8.0|^9.0|^10.0
Requires (Dev)
- pestphp/pest: ^1.21
This package is auto-updated.
Last update: 2024-09-13 17:40:40 UTC
README
crud-fast 是一个 Laravel 包,允许您在 Laravel 中自动化一些 artisan 命令。例如,我们提供了以下命令:
php artisan make:model NomDuModel
php artisan make:controller MonModelController
php artisan make:migration create_example_table
Route::resource('home', 'HomeController');
......
此包旨在减少在 Laravel 项目中输入的常用命令数量,并简化我们经常在快速进行 CRUD 操作时创建的常见视图。
下一步将是:通过提示配置迁移
,创建视图的默认内容
,以及在控制器中设置必要的内容
,使用户比之前更快。
此包可以创建:
控制器
迁移
视图
create.blade.php
edit.blade.php
show.blade.php
index.blade.php
如何安装和执行此包
首先,您需要在一个支持 php
语言的环境中使用以下命令,并选择这些框架之一(首选 Laravel):
composer require perrin/crud-fast:dev-main
如何使用此包
设置示例
php artisan crudfast:install Exemple
卸载示例
php artisan crudfast:install Exemple
注意
在您的 web.php
中,不要忘记在之前创建的控制器类之前导入
如何为此项目做出贡献
这是一个开源包,因此您可以贡献并添加您的贡献到这个项目中
测试
composer require perrin/crud-fast:dev-main
安装
php artisan crudfast:install Persone
卸载
php artisan crudfast:install Persone
结论
此包允许您在 CRUD 或其他 MVC 创建中更快地设置。当前版本为 1.0,后续将会有更多改进
请开始使用 📖