<?php

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

class CreateTracerStudiesTable extends Migration
{
    /**
     * Jalankan migration untuk membuat tabel tracer_studies.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('tracer_studies', function (Blueprint $table) {
            $table->id();
            $table->string('kampus');
            $table->string('slug_kampus');
            $table->string('jurusan');
            $table->string('nama');
            $table->string('email');
            $table->string('foto')->nullable();  // Foto optional
            $table->string('tahun_lulus')->nullable();
            $table->string('job')->nullable();  // Pekerjaan
            $table->boolean('is_prestasi')->default(false);  // Prestasi
            $table->timestamps();
        });
    }

    /**
     * Membatalkan perubahan yang dilakukan oleh migration ini.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('tracer_studies');
    }
}
