|
@@ -0,0 +1,29 @@
|
|
|
+<?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('user_domain_blocks', function (Blueprint $table) {
|
|
|
+ $table->id();
|
|
|
+ $table->unsignedBigInteger('profile_id')->index();
|
|
|
+ $table->string('domain');
|
|
|
+ $table->unique(['profile_id', 'domain'], 'user_domain_blocks_by_id');
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * Reverse the migrations.
|
|
|
+ */
|
|
|
+ public function down(): void
|
|
|
+ {
|
|
|
+ Schema::dropIfExists('user_domain_blocks');
|
|
|
+ }
|
|
|
+};
|