Files
cssd-back/database/migrations/2023_12_05_124700_update_items_table4.php
T
2023-12-07 10:00:19 +03:30

34 lines
711 B
PHP

<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class UpdateItemsTable4 extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::drop('item_package');
Schema::table('items', function (Blueprint $table) {
$table->unsignedBigInteger('package_id')->nullable()->after("id");
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('items', function (Blueprint $table) {
$table->dropColumn('package_id');
});
}
}