Add provider tag verification

This commit is contained in:
Codex
2026-07-10 17:55:52 -05:00
parent 3b856b5e46
commit 71434c1ac4
14 changed files with 504 additions and 11 deletions
@@ -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
{
public function up(): void
{
Schema::create('provider_tag_verifications', function (Blueprint $table) {
$table->id();
$table->foreignId('work_order_id')->constrained()->cascadeOnDelete();
$table->foreignId('provider_profile_id')->constrained()->cascadeOnDelete();
$table->foreignId('buyer_id')->constrained('users')->cascadeOnDelete();
$table->foreignId('provider_id')->constrained('users')->cascadeOnDelete();
$table->unsignedTinyInteger('declared_level')->nullable();
$table->unsignedTinyInteger('confirmed_level')->nullable();
$table->string('level_verdict')->default('not_observed');
$table->json('confirmed_term_ids')->nullable();
$table->json('disputed_term_ids')->nullable();
$table->json('suggested_tags')->nullable();
$table->text('notes')->nullable();
$table->timestamps();
$table->unique('work_order_id');
$table->index(['provider_profile_id', 'level_verdict']);
});
}
public function down(): void
{
Schema::dropIfExists('provider_tag_verifications');
}
};