🌈 Skin Chromas

This commit is contained in:
Rico van Zelst
2023-10-27 10:20:17 +02:00
parent bb771faf25
commit 021eae9bf4
11 changed files with 297 additions and 9 deletions

View File

@@ -15,7 +15,7 @@ return new class extends Migration
$table->id();
$table->integer('champion_id');
$table->integer('full_skin_id');
$table->unsignedBigInteger('full_skin_id')->unique();
$table->integer('skin_id');
$table->string('skin_name');
$table->longText('lore');

View File

@@ -0,0 +1,35 @@
<?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('skin_chromas', function (Blueprint $table) {
$table->id();
$table->unsignedBigInteger('full_skin_id');
$table->string('skin_name');
$table->string('chroma_name');
$table->json('chroma_colors');
$table->string('chroma_image');
$table->foreign('full_skin_id')->references('full_skin_id')->on('champion_skins');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('skin_chromas');
}
};