<?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('barobill_card_transactions', function (Blueprint $table) {
            $table->decimal('modified_supply_amount', 18, 2)->nullable()->after('tax')
                ->comment('사용자 수정 공급가액 (null이면 원본값 사용)');
            $table->decimal('modified_tax', 18, 2)->nullable()->after('modified_supply_amount')
                ->comment('사용자 수정 부가세 (null이면 원본값 사용)');
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::table('barobill_card_transactions', function (Blueprint $table) {
            $table->dropColumn(['modified_supply_amount', 'modified_tax']);
        });
    }
};
