2025-01-04 03:22:13 +02: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('seasons', function (Blueprint $table) {
|
|
|
|
|
$table->id();
|
|
|
|
|
$table->date('air_date')->nullable();
|
|
|
|
|
$table->integer('episode_count')->nullable();
|
2025-01-07 23:39:22 +02:00
|
|
|
$table->bigInteger('tmdb_id')->nullable();
|
2025-01-04 03:22:13 +02:00
|
|
|
$table->string('name')->nullable();
|
|
|
|
|
$table->string('slug')->nullable();
|
|
|
|
|
$table->text('overview')->nullable();
|
|
|
|
|
$table->string('poster_path', 500)->nullable();
|
|
|
|
|
$table->integer('season_number')->nullable();
|
|
|
|
|
$table->decimal('vote_average', 10, 2)->nullable();
|
|
|
|
|
$table->unsignedBigInteger('show_id');
|
|
|
|
|
$table->timestamps();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Reverse the migrations.
|
|
|
|
|
*/
|
|
|
|
|
public function down(): void
|
|
|
|
|
{
|
|
|
|
|
Schema::dropIfExists('seasons');
|
|
|
|
|
}
|
|
|
|
|
};
|