chatbox-inc/laravel-transaction 问题修复 & 功能扩展

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

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

chatbox-inc/laravel-transaction

最新稳定版本:1.0.3

Composer 安装命令:

composer require chatbox-inc/laravel-transaction

包简介

README 文档

README

Latest Stable Version License

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-03-04