<?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::create('keyword_audits',function(Blueprint $t){$t->id();$t->foreignId('actor_user_id')->nullable()->constrained('users')->nullOnDelete();$t->foreignId('keyword_id')->nullable()->constrained('keywords')->nullOnDelete();$t->foreignId('project_id')->constrained()->restrictOnDelete();$t->string('action',40)->index();$t->uuid('correlation_id')->index();$t->json('before')->nullable();$t->json('after')->nullable();$t->timestamps();});}public function down():void{Schema::dropIfExists('keyword_audits');}};
