chatbox-inc/laravel-transaction
最新稳定版本:1.0.3
Composer 安装命令:
composer require chatbox-inc/laravel-transaction
包简介
README 文档
README
This - Laravel Transaction provide Auto Transaction to your Laravel Application.
Install
You can install via composer
$ composer require chatbox-inc/laravel-transaction
Usage
You can use middleware \Chatbox\LaravelTransaction\Http\Middleware\LaravelTransactionMiddleware.
if you load LaravelTransactionServiceProvider (normally auto discovered),
you can use middleware alias transact_db .
Global Usage
If you need transaction to your all routes,
add middleware in the $middleware property of app/Http/Kernel.php
protected $middleware = [ // ... \Chatbox\LaravelTransaction\Http\Middleware\LaravelTransactionMiddleware::class ];
or you can apply it to middleware group by using $middlewareGroups property .
protected $middlewareGroups = [ // ... 'api' => [ // ... \Chatbox\LaravelTransaction\Http\Middleware\LaravelTransactionMiddleware::class ], ];
With LaravelTransactionServiceProvider (normally auto discovered), you can use alias transact_db.
protected $middlewareGroups = [ // ... 'api' => [ // ... "transact_db" ], ];
Of caurse, you can use this middleware per route if you need.
统计信息
- 总下载量: 3.45k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-03-04