<?php

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

class AlterPostulationsSuppliersAddOfferFields extends Migration
{
    public function up()
    {
        Schema::table('postulations_suppliers', function (Blueprint $table) {
            $table->timestamp('date_1')->nullable()->after('suppliers_id');
            $table->timestamp('date_2')->nullable()->after('date_1');
            $table->float('amount')->nullable()->after('date_2');
        });
    }

    public function down()
    {
        Schema::table('postulations_suppliers', function (Blueprint $table) {
            $table->dropColumn(['date_1', 'date_2', 'amount']);
        });
    }
}
