movie-night-api/database/migrations/2026_02_17_011759_create_profiles_table.php

34 lines
872 B
PHP
Raw Permalink Normal View History

2026-02-18 00:15:02 -06:00
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
Schema::create('profiles', function (Blueprint $table) {
$table->id();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->string('first_name')->nullable();
$table->string('last_name')->nullable();
$table->string('location')->nullable();
$table->string('bio')->nullable();
$table->string('profile_image')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('profiles');
}
};