qayum/api-first-crud-generator
最新稳定版本:0.0.1
Composer 安装命令:
composer require qayum/api-first-crud-generator
包简介
Generates a complete curd operation
README 文档
README
Laravel | API First CRUD Generator
This Generator package provides generators of Models, Controllers, Request, Routes for a painless development.
INSTALL
Install the package through Composer.
Run the Composer require command from the Terminal:
composer require qayum/api-first-crud-generator --dev
USAGE
Usage of this package is very simple.
First, let's supposing I want to generate CRUD.
So, we run
php artisan make:crud Product
No further options required. It will create a controller,model,validation,migration file and API routes!
ROUTING
Routes will follow Route::apiResource() Schema (default routing schema provided by Laravel).
Example: i'm generating Product crud
| Route | Method | Operation |
|---|---|---|
| products | GET | Get all products |
| products/{id} | GET | Find product by id |
| products | POST | Insert a new product |
| products/{id} | PUT / PATCH | Update product by id |
| products/{id} | DELETE | Delete product by id |
Remember that all api routes have 'api/' prefix.
AUTHORS
This package has been originally developed by Qayum Hasan
统计信息
- 总下载量: 6
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-08-30