Migration: Add column 'legacy_code' to 'units_list'
This commit is contained in:
miroman-afk
2022-01-12 23:53:36 +03:00
parent cf1e228f26
commit 51a27b005e
2 changed files with 29 additions and 90 deletions

View File

@@ -0,0 +1,29 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddColumnsToUnitsList extends Migration {
/**
* Run the migrations.
*
* @return void
*/
public function up() {
Schema::table('units_list', function (Blueprint $table) {
$table->string('legacy_code')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down() {
Schema::table('units_list', function (Blueprint $table) {
$table->dropColumn('legacy_code');
});
}
}