<?php

namespace App\Database\Migrations;

use CodeIgniter\Database\Migration;

class AddJenisJabatanToPengajuan extends Migration
{
    public function up()
    {
        $fields = [
            'jenis_jabatan' => [
                'type' => 'ENUM',
                'constraint' => ['Jabatan Struktural', 'Jabatan Fungsional', 'Jabatan Fungsional Umum/Pelaksana'],
                'null' => true,
                'after' => 'jenis_kp'
            ],
        ];
        $this->forge->addColumn('pengajuan', $fields);
    }

    public function down()
    {
        $this->forge->dropColumn('pengajuan', 'jenis_jabatan');
    }
}
