<?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::create('pengajuan_pemutihans', function (Blueprint $table) {
            $table->id();
            $table->string('caseid');
            $table->unsignedBigInteger('dosen_id');
            $table->string('program_studi');
            $table->string('mata_kuliah');
            $table->string('ruang_kelas');
            $table->string('tanggal_kelas');
            $table->string('jam_kelas');
            $table->string('jurnal_kuliah');
            $table->string('alasan');
            $table->text('keterangan');
            $table->string('bukti_izin_dosen');
            $table->foreign('dosen_id')->references('id')->on('users')->onDelete('cascade');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('pengajuan_pemutihans');
    }
};
