keljtanoski/modular-laravel
Composer 安装命令:
composer create-project keljtanoski/modular-laravel
包简介
Personal blueprint project starter.
README 文档
README
About Modular Laravel
This project is a personal blueprint starter with customized modular / SOA architecture.
Install
You can create new Modular Laravel project using composer
composer create-project keljtanoski/modular-laravel
After the project is created run the following commands
composer install
Then generate application key
php artisan key:generate
Then create storage link
php artisan storage:link
Then run the migrations
php artisan migrate:fresh
Laravel Sail
This blueprint comes with Laravel Sail included and default configuration including mysql and redis in the docker-composer.yml file.
You can select your own setup or preference by running php artisan sail:install in the terminal and select the desired configuration.
To start Docker containers run
./vendor/bin/sail up
This will pull the docker images and start the containers.
Alternatively you can run the following command to start the Docker containers in the background
./vendor/bin/sail up -d
After the Docker containers are up and ready you can run the following command to run the migrations inside Docker
./vendor/bin/sail artisan migrate:fresh
Then run the seeders for the example modules
./vendor/bin/sail artisan db:seed
Core structure
app
├── Modules
│ └── Core
│ ├── Controllers
│ | ├── ApiController.php
| | └── Controller.php
│ ├── Exceptions
│ | ├── FormRequestTableNotFoundException.php
│ | ├── GeneralException.php
│ | ├── GeneralIndexException.php
│ | ├── GeneralSearchException.php
│ | ├── GeneralStoreException.php
│ | ├── GeneralNotFoundException.php
│ | ├── GeneralDestroyException.php
| | └── GeneralUpdateException.php
│ ├── Filters
│ | ├── QueryFilter.php
| | └── FilterBuilder.php
│ ├── Helpers
| | └── Helper.php
│ ├── Interfaces
│ | ├── FilterInterface.php
│ | ├── SearchInterface.php
| | └── RepositoryInterface.php
│ ├── Models
| | └── .gitkeep
│ ├── Repositories
| | └── Repository.php
│ ├── Requests
│ | ├── FormRequest.php
│ | ├── CreateFormRequest.php
│ | ├── DeleteFormRequest.php
│ | ├── SearchFormRequest.php
│ | ├── UpdateFormRequest.php
| | └── ShowFormRequest.php
│ ├── Resources
│ | └── .gitkeep
│ ├── Scopes
| | └── .gitkeep
│ ├── Traits
│ | ├── ApiResponses.php
| | └── Filterable.php
│ ├── Transformers
│ | ├── EmptyResource.php
| | └── EmptyResourceCollection.php
│ └──
└──
Example Module structure
app
├── Modules
│ └── Example
│ ├── Config
| | └── .gitkeep
│ ├── Controllers
│ │ ├── Api
│ │ │ └── ExamplesController.php
| | └── ExamplesController.php
│ ├── Exceptions
│ | ├── ExampleDestroyException.php
│ | ├── ExampleIndexException.php
│ | ├── ExampleNotFoundException.php
│ | ├── ExampleSearchException.php
│ | ├── ExampleStoreException.php
| | └── ExampleUpdateException.php
│ ├── Filters
│ | ├── ExampleType.php
│ | ├── ExampleTypeId.php
│ | ├── IsActive.php
| | └── Name.php
│ ├── Helpers
| | └── .gitkeep
│ ├── Interfaces
| | └── ExampleInterface.php
│ ├── Models
| | └── Example.php
│ ├── Repositories
| | └── ExampleRepository.php
│ ├── Requests
│ | ├── CreateExampleRequest.php
│ | ├── DeleteExampleRequest.php
│ | ├── SearchExampleRequest.php
│ | ├── ShowExampleRequest.php
| | └── UpdateExampleRequest.php
│ ├── Resources
│ | ├── lang
| | | └── .gitkeep
│ | └── views
| | ├── layouts
| | | └── master.blade.php
| | ├── index.blade.php
| | └── create.blade.php
│ ├── routes
│ | ├── api.php
| | └── web.php
│ ├── Services
| | └── ExampleService.php
│ ├── Traits
| | └── .gitkeep
│ ├── Transformers
| | └── ExampleResource.php
│ └──
└──
Route list
+----------+---------------------------+---------------------------+------------------------------------------------------------------------+---------------+
| Method | URI | Name | Action | Middleware |
+----------+---------------------------+---------------------------+------------------------------------------------------------------------+---------------+
| POST | api/v1/example-types | api.example_types.store | App\Modules\ExampleType\Controllers\Api\ExampleTypesController@store | api |
| GET|HEAD | api/v1/example-types | api.example_types.index | App\Modules\ExampleType\Controllers\Api\ExampleTypesController@index | api |
| DELETE | api/v1/example-types/{id} | api.example_types.destroy | App\Modules\ExampleType\Controllers\Api\ExampleTypesController@destroy | api |
| PATCH | api/v1/example-types/{id} | api.example_types.update | App\Modules\ExampleType\Controllers\Api\ExampleTypesController@update | api |
| GET|HEAD | api/v1/example-types/{id} | api.example_types.show | App\Modules\ExampleType\Controllers\Api\ExampleTypesController@show | api |
| GET|HEAD | api/v1/examples | api.examples.index | App\Modules\Example\Controllers\Api\ExamplesController@index | api |
| POST | api/v1/examples | api.examples.store | App\Modules\Example\Controllers\Api\ExamplesController@store | api |
| GET|HEAD | api/v1/examples/{id} | api.examples.show | App\Modules\Example\Controllers\Api\ExamplesController@show | api |
| PATCH | api/v1/examples/{id} | api.examples.update | App\Modules\Example\Controllers\Api\ExamplesController@update | api |
| DELETE | api/v1/examples/{id} | api.examples.destroy | App\Modules\Example\Controllers\Api\ExamplesController@destroy | api |
| POST | example-types | example_types.store | App\Modules\ExampleType\Controllers\ExampleTypesController@store | web |
| GET|HEAD | example-types | example_types.index | App\Modules\ExampleType\Controllers\ExampleTypesController@index | web |
| GET|HEAD | example-types/create | example_types.create | App\Modules\ExampleType\Controllers\ExampleTypesController@create | web |
| GET|HEAD | example-types/{id} | example_types.show | App\Modules\ExampleType\Controllers\ExampleTypesController@show | web |
| PATCH | example-types/{id} | example_types.update | App\Modules\ExampleType\Controllers\ExampleTypesController@update | web |
| DELETE | example-types/{id} | example_types.destroy | App\Modules\ExampleType\Controllers\ExampleTypesController@destroy | web |
| GET|HEAD | example-types/{id}/edit | example_types.edit | App\Modules\ExampleType\Controllers\ExampleTypesController@edit | web |
| GET|HEAD | examples | examples.index | App\Modules\Example\Controllers\ExamplesController@index | web |
| POST | examples | examples.store | App\Modules\Example\Controllers\ExamplesController@store | web |
| GET|HEAD | examples/create | examples.create | App\Modules\Example\Controllers\ExamplesController@create | web |
| DELETE | examples/{id} | examples.destroy | App\Modules\Example\Controllers\ExamplesController@destroy | web |
| PATCH | examples/{id} | examples.update | App\Modules\Example\Controllers\ExamplesController@update | web |
| GET|HEAD | examples/{id} | examples.show | App\Modules\Example\Controllers\ExamplesController@show | web |
| GET|HEAD | examples/{id}/edit | examples.edit | App\Modules\Example\Controllers\ExamplesController@edit | web |
+----------+---------------------------+---------------------------+------------------------------------------------------------------------+---------------+
License
The Laravel framework is open-sourced software licensed under the MIT license.
keljtanoski/modular-laravel 适用场景与选型建议
keljtanoski/modular-laravel 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 131 次下载、GitHub Stars 达 47, 最近一次更新时间为 2021 年 08 月 26 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「framework」 「laravel」 「laravel template」 「modular laravel」 「keljtanoski」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 keljtanoski/modular-laravel 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 keljtanoski/modular-laravel 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 keljtanoski/modular-laravel 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
PHP Framework HLEB2 is the foundation of the web application. Provides ease of development and application performance.
Simple ASCII output of array data
E2E Studios PHP Framework adaptation of leafsphp/blade package
Alfabank REST API integration
Ensolab template project
Account Balance / Wallets Manager For FilamentPHP and Filament Account Builder
统计信息
- 总下载量: 131
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 47
- 点击次数: 5
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-08-26