i have a problem with my migration on laravel 5.8. I try to make Year Column as mentioned in documentation. But i get this error "[Symfony\Component\Debug\Exception\FatalThrowableError] Call to undefined method Illuminate\Database\Schema\Blueprint::year()".
this is my migration file :
Schema::create('pengajuan_arsip', function(Blueprint $table) {
$table->increments('id');
$table->uuid('uuid');
$table->integer('id_pegawai_pengaju');
$table->string('nip_pengaju',50);
$table->string('nik_pengaju',50);
$table->string('nama_pengaju',200);
$table->string('bidang',100);
$table->string('sub_bidang',100);
$table->string('tingkat',50);
$table->integer('status');
$table->boolean('is_setuju');
$table->integer('setuju_kasi_by');
$table->year('tahun_mulai');
$table->year('tahun_akhir');
$table->timestamps();
$table->softDeletes();
});
Schema::create('detail_histori_arsip', function(Blueprint $table) {
$table->increments('id');
$table->uuid('uuid');
$table->integer('id_pengajuan_arsip');
$table->integer('status');
$table->integer('status_by');
$table->integer('diambil_by');
$table->date('tanggal_diambil');
$table->integer('id_ruang_arsip');
$table->date('tanggal_pindah');
$table->timestamps();
});
Schema::create('detail_arsip', function(Blueprint $table) {
$table->increments('id');
$table->uuid('uuid');
$table->integer('id_pengajuan_arsip');
$table->string('nama_dokumen',200);
$table->year('tahun_dokumen');
$table->timestamps();
});
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire