eelcol/laravel-blueprint-group 问题修复 & 功能扩展

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

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

eelcol/laravel-blueprint-group

最新稳定版本:1.1.0

Composer 安装命令:

composer require eelcol/laravel-blueprint-group

包简介

Laravel Blueprint group extension

README 文档

README

Sometimes, you want to group statements in your migration files. For example, when you want to add 3 new columns to a table and don't want to specify an ->after('...') on every statement. Now you can use the group method!

Example

Lets take the following migration as example:

Schema::table('table', function (Blueprint $table) {
            
	$table->string('new_column_a')->nullable()->after('some_old_column');
	$table->string('new_column_b')->nullable()->after('new_column_a');
	$table->string('new_column_c')->nullable()->after('new_column_b');

});

This can be grouped as follows:

Schema::table('table', function (Blueprint $table) {

	$table->group(function($group) {
            
		$group->string('new_column_a');
		$group->string('new_column_b');
		$group->string('new_column_c');

	})->nullable()->after('some_old_column');

});

Installation

Require this package with composer.

composer require eelcol/laravel-blueprint-group

Laravel 5.5 uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.

If you don't use auto-discovery, add the ServiceProvider to the providers array in config/app.php

Eelcol\LaravelBlueprintGroup\BlueprintGroupServiceProvider::class,

统计信息

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

GitHub 信息

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

其他信息

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

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固