<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('request_logs', function (Blueprint $table) {
            $table->integer('approved_by')->nullable()->after('created_by');
            $table->dateTime('approved_at')->nullable()->after('approved_by');
            $table->integer('approved_final_log_by')->nullable()->after('approved_at');
            $table->dateTime('approved_final_log_at')->nullable()->after('approved_final_log_by');
         
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('request_logs', function (Blueprint $table) {
            $table->dropColumn(['approved_by', 'invoice_date', 'approved_final_log_by', 'approved_final_log_at']);
        });
    }
};
