toshkq93/laravel-components 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

toshkq93/laravel-components

Composer 安装命令:

composer require toshkq93/laravel-components

包简介

add dtos, requests, resources,controller, repository and service (interface + class) in your project

README 文档

README

Install the package via composer

composer require --dev toshkq93/laravel-components

Usage

Publish the config file with:

php artisan vendor:publish --provider=Toshkq93\Components\Providers\ComponentProvider

Go to the root folder of your project and enter the command:

php artisan make:components {namespace_model} --all

Example:

php artisan make:components App/Models/User --all

and your project will create:

  • DTOs (input (App\DTO\Input) and output (App\DTO\Output) classes) + interfaces,
  • controller (App\Http\Controllers\API)
  • requests (App\Http\Requests),
  • resources (App\Http\Resources),
  • repository and service (interface (App\Contracts\Repositories) + class (App\Repositories) + base class),
  • service (interface ( App\Contracts\Services) + class (App\Services) + base class)

you can also use other flags in various combination:

  • --dto - create DTO classes input and output,
  • --controller - create controller class,
  • --resource - create resource classes,
  • --service - create service class,
  • --request - create request classes,
  • --repository - create repository class.
  • --all - all of the above

After generating services and repositories, bind is automatically added to the container in the App\Provides\AppServiceProvider.

After the controller is generated, a resource route is automatically added depending on the file name (api - apiResource, web - resource). You can also change the path to the 'route_path' route file in the configuration file.

Security

If you discover any security related issues, please email a.stanovoi170993@gmail.com instead of using the issue tracker.

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 19
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-05-19

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固