Database: Increase shift_size column size

This commit is contained in:
Xesxen 2022-05-23 23:42:20 +02:00 committed by Igor Scheller
parent b41a675a35
commit 7d51953b84
1 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,32 @@
<?php
namespace Engelsystem\Migrations;
use Engelsystem\Database\Migration\Migration;
use Illuminate\Database\Schema\Blueprint;
/**
* To allow for larger key names such as "2XL-G"
*/
class IncreaseTshirtFieldWidth extends Migration
{
/**
* Run the migration
*/
public function up()
{
$this->schema->table('users_personal_data', function (Blueprint $table) {
$table->string('shirt_size', 10)->change();
});
}
/**
* Reverse the migration
*/
public function down()
{
$this->schema->table('users_personal_data', function (Blueprint $table) {
$table->string('shirt_size', 4)->change();
});
}
}