<?php

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

class AddRetirementToEmployeePayrollsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('employee_payrolls', function (Blueprint $table) {
            $table->decimal('rt_amount_an_exhibition',15,5)->default(0);
            $table->decimal('rt_partiality_amount',15,5)->default(0);
            $table->decimal('rt_daily_amount',15,5)->default(0);
            $table->decimal('rt_cumulative_income',15,5)->default(0);
            $table->decimal('rt_non_cumulative_income',15,5)->default(0);
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('employee_payrolls', function (Blueprint $table) {
            $table->dropColumn('rt_amount_an_exhibition');
            $table->dropColumn('rt_partiality_amount');
            $table->dropColumn('rt_daily_amount');
            $table->dropColumn('rt_cumulative_income');
            $table->dropColumn('rt_non_cumulative_income');
        });
    }
}
