<?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()
    {
        Schema::table('points', function (Blueprint $table) {
            $table->decimal('segment_from', 8, 3)->nullable()->after('accounting_point');
            $table->decimal('segment_to',   8, 3)->nullable()->after('segment_from');
        });
    }

    public function down()
    {
        Schema::table('points', function (Blueprint $table) {
            $table->dropColumn(['segment_from', 'segment_to']);
        });
    }

};
