<?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::table('hardware_maestro', function (Blueprint $table) {
            $table->tinyInteger('es_de_via')
                ->default(1)
                ->after('descripcion')
                ->comment('1=Equipo de vía, 0=Equipo general');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::table('hardware_maestro', function (Blueprint $table) {
            $table->dropColumn('es_de_via');
        });
    }
};
