<?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('hasil_pengujian', function (Blueprint $table) {
            $table->id();
            $table->string('kecamatan');
            $table->integer('data_tahun')->nullable();
            $table->float('phbs');
            $table->float('imunisasi');
            $table->float('merokok');
            $table->integer('jumlah_kasus');
            $table->double('latitude');
            $table->double('longitude');
            $table->string('status_asli')->nullable();
            $table->string('status_prediksi')->nullable();
            $table->integer('prediksi_tahun')->nullable(); // ✅ Tambahkan ini
            $table->timestamps();
        });
    }

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