<?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('fiber_nodes', function (Blueprint $table) {
            $table->id();
            $table->string('name');
            $table->string('type'); // POP, OLT, Closure, Splitter, ODB, Drop
            $table->decimal('lat', 10, 7);
            $table->decimal('lng', 10, 7);
            $table->string('capacity')->default('1:8 Splitter');
            $table->string('status')->default('Active');
            $table->text('notes')->nullable();
            $table->timestamps();
        });
    }

    public function down(): void
    {
        Schema::dropIfExists('fiber_nodes');
    }
};
