feat(#21): support custom device dimensions

This commit is contained in:
Benjamin Nussbaum 2025-05-05 16:43:57 +02:00
parent b9369c224e
commit e7e1b10a04
3 changed files with 38 additions and 2 deletions

View file

@ -0,0 +1,23 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration {
public function up(): void
{
Schema::table('devices', function (Blueprint $table) {
$table->integer('width')->nullable()->default(800)->after('api_key');
$table->integer('height')->nullable()->default(480)->after('width');
});
}
public function down(): void
{
Schema::table('devices', function (Blueprint $table) {
$table->dropColumn('width');
$table->dropColumn('height');
});
}
};