diff --git a/database/migrations/2024_01_01_000001_create_siasn_referensi_agama_table.php b/database/migrations/2024_01_01_000001_create_siasn_referensi_agama_table.php index 1ca4003..51fc851 100644 --- a/database/migrations/2024_01_01_000001_create_siasn_referensi_agama_table.php +++ b/database/migrations/2024_01_01_000001_create_siasn_referensi_agama_table.php @@ -12,8 +12,8 @@ public function up(): void { Schema::create('siasn_referensi_agama', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); + $table->unsignedTinyInteger('id')->primary()->autoIncrement(false); + $table->string('nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000002_create_siasn_referensi_alasan_hukuman_disiplin_table.php b/database/migrations/2024_01_01_000002_create_siasn_referensi_alasan_hukuman_disiplin_table.php index 0c74c4b..7765cb6 100644 --- a/database/migrations/2024_01_01_000002_create_siasn_referensi_alasan_hukuman_disiplin_table.php +++ b/database/migrations/2024_01_01_000002_create_siasn_referensi_alasan_hukuman_disiplin_table.php @@ -13,8 +13,8 @@ public function up(): void { Schema::create('siasn_referensi_alasan_hukuman_disiplin', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->text('nama')->nullable(); - $table->string('keterangan')->nullable(); + $table->text('nama'); + $table->string('keterangan', 16); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000003_create_siasn_referensi_asn_jenis_jabatan_table.php b/database/migrations/2024_01_01_000003_create_siasn_referensi_asn_jenis_jabatan_table.php index 18f152d..95ce704 100644 --- a/database/migrations/2024_01_01_000003_create_siasn_referensi_asn_jenis_jabatan_table.php +++ b/database/migrations/2024_01_01_000003_create_siasn_referensi_asn_jenis_jabatan_table.php @@ -13,7 +13,7 @@ public function up(): void { Schema::create('siasn_referensi_asn_jenis_jabatan', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); + $table->string('nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000004_create_siasn_referensi_asn_jenjang_jabatan_table.php b/database/migrations/2024_01_01_000004_create_siasn_referensi_asn_jenjang_jabatan_table.php index b7125ab..90f0762 100644 --- a/database/migrations/2024_01_01_000004_create_siasn_referensi_asn_jenjang_jabatan_table.php +++ b/database/migrations/2024_01_01_000004_create_siasn_referensi_asn_jenjang_jabatan_table.php @@ -12,10 +12,10 @@ public function up(): void { Schema::create('siasn_referensi_asn_jenjang_jabatan', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('asnJenisJabatanId', 42)->nullable(); - $table->string('level')->nullable(); + $table->string('id', 2)->primary(); + $table->string('nama'); + $table->string('asnJenisJabatanId', 2); + $table->unsignedTinyInteger('level', 1)->autoIncrement(false); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000005_create_siasn_referensi_eselon_table.php b/database/migrations/2024_01_01_000005_create_siasn_referensi_eselon_table.php index 9195146..4de6652 100644 --- a/database/migrations/2024_01_01_000005_create_siasn_referensi_eselon_table.php +++ b/database/migrations/2024_01_01_000005_create_siasn_referensi_eselon_table.php @@ -12,14 +12,14 @@ public function up(): void { Schema::create('siasn_referensi_eselon', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('terendah_id')->nullable(); - $table->string('tertinggi_id')->nullable(); - $table->string('eselon_level_id')->nullable(); - $table->string('asn_jenjang_jabatan_id')->nullable(); - $table->string('jabatan_asn')->nullable(); - $table->string('level_kompetensi_jabatan')->nullable(); + $table->string('id', 2)->primary(); + $table->string('nama'); + $table->unsignedTinyInteger('terendah_id')->autoIncrement(false); + $table->unsignedTinyInteger('tertinggi_id')->autoIncrement(false); + $table->unsignedTinyInteger('eselon_level_id', 1)->autoIncrement(false); + $table->string('asn_jenjang_jabatan_id', 2); + $table->string('jabatan_asn'); + $table->string('level_kompetensi_jabatan'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000006_create_siasn_referensi_golongan_table.php b/database/migrations/2024_01_01_000006_create_siasn_referensi_golongan_table.php index 2484404..f110323 100644 --- a/database/migrations/2024_01_01_000006_create_siasn_referensi_golongan_table.php +++ b/database/migrations/2024_01_01_000006_create_siasn_referensi_golongan_table.php @@ -12,12 +12,12 @@ public function up(): void { Schema::create('siasn_referensi_golongan', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('namaPangkat')->nullable(); - $table->string('fungKredututama')->nullable(); - $table->string('fungKreditTambahan')->nullable(); - $table->string('fungKreditTotal')->nullable(); + $table->unsignedTinyInteger('id', 2)->primary()->autoIncrement(false); + $table->string('nama'); + $table->string('namaPangkat'); + $table->unsignedSmallInteger('fungKredututama')->autoIncrement(false); + $table->unsignedSmallInteger('fungKreditTambahan')->autoIncrement(false); + $table->unsignedSmallInteger('fungKreditTotal')->autoIncrement(false); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000007_create_siasn_referensi_instansi_table.php b/database/migrations/2024_01_01_000007_create_siasn_referensi_instansi_table.php index 7b7a661..b8da29d 100644 --- a/database/migrations/2024_01_01_000007_create_siasn_referensi_instansi_table.php +++ b/database/migrations/2024_01_01_000007_create_siasn_referensi_instansi_table.php @@ -13,18 +13,18 @@ public function up(): void { Schema::create('siasn_referensi_instansi', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('lokasiId', 42)->nullable(); - $table->string('nama')->nullable(); - $table->string('jenis')->nullable(); - $table->string('cepatKode')->nullable(); - $table->string('prosesBerkasDipusat')->nullable(); - $table->string('mgrCepatKode')->nullable(); - $table->string('status')->nullable(); - $table->string('cepatKode5')->nullable(); - $table->string('cepatKode5Lama')->nullable(); - $table->string('namaBaru')->nullable(); - $table->string('namaJabatan')->nullable(); - $table->string('jenisInstansiId', 42)->nullable(); + $table->string('lokasiId', 42); + $table->string('nama'); + $table->string('jenis', 1); + $table->string('cepatKode', 10); + $table->string('prosesBerkasDipusat'); + $table->string('mgrCepatKode'); + $table->string('status', 1); + $table->string('cepatKode5', 10); + $table->string('cepatKode5Lama', 10); + $table->string('namaBaru'); + $table->string('namaJabatan'); + $table->string('jenisInstansiId', 8); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000008_create_siasn_referensi_jabatan_fungsional_table.php b/database/migrations/2024_01_01_000008_create_siasn_referensi_jabatan_fungsional_table.php index c7b3dee..089cdd0 100644 --- a/database/migrations/2024_01_01_000008_create_siasn_referensi_jabatan_fungsional_table.php +++ b/database/migrations/2024_01_01_000008_create_siasn_referensi_jabatan_fungsional_table.php @@ -13,30 +13,30 @@ public function up(): void { Schema::create('siasn_referensi_jabatan_fungsional', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('min_gol_id')->nullable(); - $table->string('max_gol_id')->nullable(); - $table->string('nama')->nullable(); - $table->string('bup_usia')->nullable(); - $table->string('tun_jabatan')->nullable(); - $table->string('bobot')->nullable(); - $table->string('kel_jabatan_id')->nullable(); - $table->string('cepat_kode')->nullable(); - $table->string('mgr_cepat_kode')->nullable(); - $table->string('jenis')->nullable(); - $table->string('cepat_kode_new')->nullable(); - $table->string('status')->nullable(); - $table->string('jml_formasi')->nullable(); - $table->string('nama_asli')->nullable(); - $table->string('jenjang')->nullable(); - $table->string('jf_ex_medis')->nullable(); - $table->string('is_syarat_jabatan')->nullable(); - $table->string('jenis_jabatan_id')->nullable(); - $table->string('jenis_jabatan_nama')->nullable(); - $table->string('kode_jenjang_jabatan')->nullable(); - $table->string('asn_jenjang_jabatan')->nullable(); - $table->string('level')->nullable(); - $table->string('rumpun_jabatan_id')->nullable(); - $table->string('rumpun_jabatan_nama')->nullable(); + $table->unsignedTinyInteger('min_gol_id')->autoIncrement(false); + $table->unsignedTinyInteger('max_gol_id')->autoIncrement(false); + $table->string('nama'); + $table->unsignedTinyInteger('bup_usia', 2)->autoIncrement(false); + $table->unsignedInteger('tun_jabatan')->autoIncrement(false); + $table->unsignedSmallInteger('bobot')->autoIncrement(false); + $table->string('kel_jabatan_id'); + $table->string('cepat_kode', 10); + $table->string('mgr_cepat_kode', 10); + $table->string('jenis', 1)->autoIncrement(false); + $table->string('cepat_kode_new', 10); + $table->string('status', 1); + $table->unsignedInteger('jml_formasi')->autoIncrement(false); + $table->string('nama_asli'); + $table->string('jenjang', 2); + $table->string('jf_ex_medis', 1); + $table->string('is_syarat_jabatan', 1); + $table->string('jenis_jabatan_id'); + $table->string('jenis_jabatan_nama'); + $table->string('kode_jenjang_jabatan'); + $table->string('asn_jenjang_jabatan'); + $table->string('level'); + $table->string('rumpun_jabatan_id'); + $table->string('rumpun_jabatan_nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000009_create_siasn_referensi_jabatan_fungsional_umum_table.php b/database/migrations/2024_01_01_000009_create_siasn_referensi_jabatan_fungsional_umum_table.php index e45d380..e94645f 100644 --- a/database/migrations/2024_01_01_000009_create_siasn_referensi_jabatan_fungsional_umum_table.php +++ b/database/migrations/2024_01_01_000009_create_siasn_referensi_jabatan_fungsional_umum_table.php @@ -13,23 +13,23 @@ public function up(): void { Schema::create('siasn_referensi_jabatan_fungsional_umum', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('cepat_kode')->nullable(); - $table->string('wajib_ganti_tertentu')->nullable(); - $table->string('mgr_cepat_kode')->nullable(); - $table->string('nama_asli')->nullable(); - $table->string('kode_menpan')->nullable(); - $table->string('instansi_id')->nullable(); - $table->string('status')->nullable(); - $table->string('asal_peraturan_id')->nullable(); - $table->string('jfu_urusan_pemerintahan')->nullable(); - $table->string('jenis_jabatan_umum_id')->nullable(); - $table->string('jenis_jabatan_umum_nama')->nullable(); - $table->string('asn_jenjang_jabatan_id')->nullable(); - $table->string('asn_jenjang_jabatan_nama')->nullable(); - $table->string('level')->nullable(); - $table->string('ref_urusan_pemerintahan_id')->nullable(); - $table->string('ref_urusan_pemerintahan_nama')->nullable(); + $table->string('nama'); + $table->string('cepat_kode', 10); + $table->string('wajib_ganti_tertentu', 1); + $table->string('mgr_cepat_kode', 10); + $table->string('nama_asli'); + $table->string('kode_menpan', 16); + $table->string('instansi_id', 42); + $table->string('status', 1); + $table->boolean('asal_peraturan_id'); + $table->unsignedInteger('jfu_urusan_pemerintahan')->autoIncrement(false); + $table->unsignedTinyInteger('jenis_jabatan_umum_id'); + $table->string('jenis_jabatan_umum_nama'); + $table->string('asn_jenjang_jabatan_id'); + $table->string('asn_jenjang_jabatan_nama'); + $table->string('level'); + $table->string('ref_urusan_pemerintahan_id', 42); + $table->string('ref_urusan_pemerintahan_nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000010_create_siasn_referensi_jenis_anak_table.php b/database/migrations/2024_01_01_000010_create_siasn_referensi_jenis_anak_table.php index 445967b..8da36df 100644 --- a/database/migrations/2024_01_01_000010_create_siasn_referensi_jenis_anak_table.php +++ b/database/migrations/2024_01_01_000010_create_siasn_referensi_jenis_anak_table.php @@ -12,8 +12,8 @@ public function up(): void { Schema::create('siasn_referensi_jenis_anak', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); + $table->unsignedTinyInteger('id')->primary(); + $table->string('nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000011_create_siasn_referensi_jenis_hukuman_table.php b/database/migrations/2024_01_01_000011_create_siasn_referensi_jenis_hukuman_table.php index 4a50d4c..11f34ab 100644 --- a/database/migrations/2024_01_01_000011_create_siasn_referensi_jenis_hukuman_table.php +++ b/database/migrations/2024_01_01_000011_create_siasn_referensi_jenis_hukuman_table.php @@ -12,9 +12,9 @@ public function up(): void { Schema::create('siasn_referensi_jenis_hukuman', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('jenisTingkatHukumanId', 42)->nullable(); + $table->string('id', 2)->primary(); + $table->string('nama'); + $table->string('jenisTingkatHukumanId', 1); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000012_create_siasn_referensi_jenis_jabatan_table.php b/database/migrations/2024_01_01_000012_create_siasn_referensi_jenis_jabatan_table.php index c59f677..58e46c9 100644 --- a/database/migrations/2024_01_01_000012_create_siasn_referensi_jenis_jabatan_table.php +++ b/database/migrations/2024_01_01_000012_create_siasn_referensi_jenis_jabatan_table.php @@ -12,8 +12,8 @@ public function up(): void { Schema::create('siasn_referensi_jenis_jabatan', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); + $table->unsignedTinyInteger('id')->primary(); + $table->string('nama'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000013_create_siasn_referensi_kanreg_table.php b/database/migrations/2024_01_01_000013_create_siasn_referensi_kanreg_table.php index 67e5c88..7c1ac77 100644 --- a/database/migrations/2024_01_01_000013_create_siasn_referensi_kanreg_table.php +++ b/database/migrations/2024_01_01_000013_create_siasn_referensi_kanreg_table.php @@ -12,12 +12,12 @@ public function up(): void { Schema::create('siasn_referensi_kanreg', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('regKota')->nullable(); - $table->string('nama')->nullable(); - $table->string('pengenal')->nullable(); - $table->string('satuanKerjaId', 42)->nullable(); - $table->string('tanggalJorge')->nullable(); + $table->string('id', 2)->primary(); + $table->string('regKota'); + $table->string('nama'); + $table->string('pengenal', 1); + $table->string('satuanKerjaId', 42); + $table->string('tanggalJorge'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000014_create_siasn_referensi_kedudukan_hukum_table.php b/database/migrations/2024_01_01_000014_create_siasn_referensi_kedudukan_hukum_table.php index 2ee3b40..e7e90b2 100644 --- a/database/migrations/2024_01_01_000014_create_siasn_referensi_kedudukan_hukum_table.php +++ b/database/migrations/2024_01_01_000014_create_siasn_referensi_kedudukan_hukum_table.php @@ -12,10 +12,10 @@ public function up(): void { Schema::create('siasn_referensi_kedudukan_hukum', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('aturan')->nullable(); - $table->string('kode')->nullable(); + $table->string('id', 2)->primary(); + $table->string('nama'); + $table->string('aturan'); + $table->string('kode', 3); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000015_create_siasn_referensi_kel_jabatan_table.php b/database/migrations/2024_01_01_000015_create_siasn_referensi_kel_jabatan_table.php index c950580..d461e23 100644 --- a/database/migrations/2024_01_01_000015_create_siasn_referensi_kel_jabatan_table.php +++ b/database/migrations/2024_01_01_000015_create_siasn_referensi_kel_jabatan_table.php @@ -13,19 +13,19 @@ public function up(): void { Schema::create('siasn_referensi_kel_jabatan', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('rumpunJabatanId', 42)->nullable(); - $table->string('nama')->nullable(); - $table->string('lingkup')->nullable(); - $table->text('tugasPokok')->nullable(); - $table->text('pejabatPak')->nullable(); - $table->string('pembinaId', 42)->nullable(); - $table->string('jenisJabatanUmumId', 42)->nullable(); - $table->string('status')->nullable(); - $table->string('kodeRumpun')->nullable(); - $table->string('kodeKelompok')->nullable(); - $table->string('jenisJabatanUmumBaruId', 42)->nullable(); - $table->string('kesehatanNonmedis')->nullable(); - $table->string('refUrusanPemerintahanId', 42)->nullable(); + $table->string('rumpunJabatanId', 42); + $table->string('nama'); + $table->string('lingkup', 1); + $table->text('tugasPokok'); + $table->text('pejabatPak'); + $table->string('pembinaId', 42); + $table->unsignedTinyInteger('jenisJabatanUmumId'); + $table->string('status', 1); + $table->string('kodeRumpun', 4); + $table->string('kodeKelompok', 4); + $table->string('jenisJabatanUmumBaruId', 1); + $table->boolean('kesehatanNonmedis'); + $table->string('refUrusanPemerintahanId'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000016_create_siasn_referensi_latihan_struktural_table.php b/database/migrations/2024_01_01_000016_create_siasn_referensi_latihan_struktural_table.php index ddc8054..551352b 100644 --- a/database/migrations/2024_01_01_000016_create_siasn_referensi_latihan_struktural_table.php +++ b/database/migrations/2024_01_01_000016_create_siasn_referensi_latihan_struktural_table.php @@ -12,11 +12,11 @@ public function up(): void { Schema::create('siasn_referensi_latihan_struktural', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('nama')->nullable(); - $table->string('eselon_level')->nullable(); - $table->string('ncsistime')->nullable(); - $table->string('struktural_pns')->nullable(); + $table->unsignedTinyInteger('id')->primary(); + $table->string('nama'); + $table->string('eselon_level', 1); + $table->string('ncsistime'); + $table->string('struktural_pns', 1); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000017_create_siasn_referensi_lokasi_table.php b/database/migrations/2024_01_01_000017_create_siasn_referensi_lokasi_table.php index f3d07ef..ff59f79 100644 --- a/database/migrations/2024_01_01_000017_create_siasn_referensi_lokasi_table.php +++ b/database/migrations/2024_01_01_000017_create_siasn_referensi_lokasi_table.php @@ -13,17 +13,17 @@ public function up(): void { Schema::create('siasn_referensi_lokasi', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('kanregId', 42)->nullable(); - $table->string('lokasiId', 42)->nullable(); - $table->string('nama')->nullable(); - $table->string('cepatKode')->nullable(); - $table->string('jenis')->nullable(); - $table->string('jenisKabupaten')->nullable(); - $table->string('removalDate')->nullable(); - $table->string('jenisDesa')->nullable(); - $table->string('tanggalJorge')->nullable(); - $table->string('mgrCepatKode')->nullable(); - $table->string('ibukota')->nullable(); + $table->string('kanregId', 2); + $table->string('lokasiId', 42); + $table->string('nama'); + $table->string('cepatKode', 10); + $table->string('jenis', 2); + $table->string('jenisKabupaten', 4); + $table->string('removalDate'); + $table->string('jenisDesa'); + $table->string('tanggalJorge'); + $table->string('mgrCepatKode', 10); + $table->string('ibukota'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000018_create_siasn_referensi_pendidikan_table.php b/database/migrations/2024_01_01_000018_create_siasn_referensi_pendidikan_table.php index dfa4102..98e277b 100644 --- a/database/migrations/2024_01_01_000018_create_siasn_referensi_pendidikan_table.php +++ b/database/migrations/2024_01_01_000018_create_siasn_referensi_pendidikan_table.php @@ -13,15 +13,15 @@ public function up(): void { Schema::create('siasn_referensi_pendidikan', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('tingkat_pendidikan_id')->nullable(); - $table->string('nama')->nullable(); - $table->string('cepat_kode')->nullable(); - $table->string('mgr_cepat_kode')->nullable(); - $table->string('nama_asli')->nullable(); - $table->string('status')->nullable(); - $table->string('subrumpun_prog_id')->nullable(); - $table->string('cepat_kode_induk')->nullable(); - $table->string('subrumpun_prog_kode')->nullable(); + $table->unsignedTinyInteger('tingkat_pendidikan_id', 2)->autoIncrement(false); + $table->string('nama'); + $table->string('cepat_kode', 10); + $table->string('mgr_cepat_kode', 10); + $table->string('nama_asli'); + $table->boolean('status'); + $table->string('subrumpun_prog_id', 8); + $table->string('cepat_kode_induk', 10); + $table->string('subrumpun_prog_kode', 8); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000019_create_siasn_referensi_ref_dokumen_table.php b/database/migrations/2024_01_01_000019_create_siasn_referensi_ref_dokumen_table.php index fac1244..41636f9 100644 --- a/database/migrations/2024_01_01_000019_create_siasn_referensi_ref_dokumen_table.php +++ b/database/migrations/2024_01_01_000019_create_siasn_referensi_ref_dokumen_table.php @@ -12,18 +12,18 @@ public function up(): void { Schema::create('siasn_referensi_ref_dokumen', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('layananId', 42)->nullable(); - $table->string('layananNama')->nullable(); - $table->string('subLayananId', 42)->nullable(); - $table->string('subLayananNama')->nullable(); - $table->string('detailLayananId', 42)->nullable(); - $table->string('detailLayananNama')->nullable(); - $table->string('document')->nullable(); - $table->string('jenisDokumen')->nullable(); - $table->string('fileType')->nullable(); - $table->string('linkProses')->nullable(); - $table->string('mandatory')->nullable(); + $table->unsignedSmallInteger('id')->primary(); + $table->unsignedSmallInteger('layananId')->autoIncrement(false); + $table->string('layananNama'); + $table->unsignedSmallInteger('subLayananId')->autoIncrement(false); + $table->string('subLayananNama'); + $table->string('detailLayananId'); + $table->string('detailLayananNama'); + $table->string('document'); + $table->string('jenisDokumen', 1); + $table->string('fileType', 8); + $table->string('linkProses', 4); + $table->boolean('mandatory'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000020_create_siasn_referensi_ref_jenjang_jf_table.php b/database/migrations/2024_01_01_000020_create_siasn_referensi_ref_jenjang_jf_table.php index ded030b..836caf2 100644 --- a/database/migrations/2024_01_01_000020_create_siasn_referensi_ref_jenjang_jf_table.php +++ b/database/migrations/2024_01_01_000020_create_siasn_referensi_ref_jenjang_jf_table.php @@ -12,10 +12,10 @@ public function up(): void { Schema::create('siasn_referensi_ref_jenjang_jf', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('deskripsi')->nullable(); - $table->string('peraturan')->nullable(); - $table->string('kode')->nullable(); + $table->string('id', 2)->primary(); + $table->string('deskripsi'); + $table->string('peraturan'); + $table->unsignedTinyInteger('kode')->autoIncrement(false); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000021_create_siasn_referensi_satuan_kerja_table.php b/database/migrations/2024_01_01_000021_create_siasn_referensi_satuan_kerja_table.php index 916ae41..4d7424d 100644 --- a/database/migrations/2024_01_01_000021_create_siasn_referensi_satuan_kerja_table.php +++ b/database/migrations/2024_01_01_000021_create_siasn_referensi_satuan_kerja_table.php @@ -13,13 +13,13 @@ public function up(): void { Schema::create('siasn_referensi_satuan_kerja', function (Blueprint $table) { $table->string('id', 42)->primary(); - $table->string('kanregId', 42)->nullable(); - $table->string('lokasiId', 42)->nullable(); - $table->string('instansiId', 42)->nullable(); - $table->string('nama')->nullable(); - $table->string('parentId', 42)->nullable(); - $table->string('jenisSatuanKerjaId', 42)->nullable(); - $table->string('unblockCode')->nullable(); + $table->string('kanregId', 2); + $table->string('lokasiId', 42); + $table->string('instansiId', 42); + $table->string('nama'); + $table->string('parentId', 42); + $table->string('jenisSatuanKerjaId', 2); + $table->string('unblockCode', 8); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000022_create_siasn_referensi_tingkat_pendidikan_table.php b/database/migrations/2024_01_01_000022_create_siasn_referensi_tingkat_pendidikan_table.php index a43767c..f369787 100644 --- a/database/migrations/2024_01_01_000022_create_siasn_referensi_tingkat_pendidikan_table.php +++ b/database/migrations/2024_01_01_000022_create_siasn_referensi_tingkat_pendidikan_table.php @@ -12,13 +12,13 @@ public function up(): void { Schema::create('siasn_referensi_tingkat_pendidikan', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('golongan_id')->nullable(); - $table->string('nama')->nullable(); - $table->string('golongan_awal_id')->nullable(); - $table->string('id_lama')->nullable(); - $table->string('group_tk_pend_id')->nullable(); - $table->string('group_tk_pend_nm')->nullable(); + $table->string('id', 2)->primary(); + $table->unsignedTinyInteger('golongan_id')->autoIncrement(false); + $table->string('nama'); + $table->unsignedTinyInteger('golongan_awal_id')->autoIncrement(false); + $table->string('id_lama', 2); + $table->unsignedTinyInteger('group_tk_pend_id')->autoIncrement(false); + $table->string('group_tk_pend_nm'); $table->timestamps(); $table->softDeletes(); }); diff --git a/database/migrations/2024_01_01_000023_create_siasn_referensi_jenis_diklat_table.php b/database/migrations/2024_01_01_000023_create_siasn_referensi_jenis_diklat_table.php index 6ba7c5b..dac7294 100644 --- a/database/migrations/2024_01_01_000023_create_siasn_referensi_jenis_diklat_table.php +++ b/database/migrations/2024_01_01_000023_create_siasn_referensi_jenis_diklat_table.php @@ -12,8 +12,8 @@ public function up(): void { Schema::create('siasn_referensi_jenis_diklat', function (Blueprint $table) { - $table->string('id', 42)->primary(); - $table->string('jenis_diklat')->nullable(); + $table->unsignedTinyInteger('id')->primary(); + $table->string('jenis_diklat'); $table->timestamps(); $table->softDeletes(); }); diff --git a/src/Models/Eselon.php b/src/Models/Eselon.php index 41f1929..8f112a3 100644 --- a/src/Models/Eselon.php +++ b/src/Models/Eselon.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class Eselon extends Model @@ -31,4 +32,19 @@ class Eselon extends Model * @var array */ protected $guarded = []; + + public function jenjangJabatan(): BelongsTo + { + return $this->belongsTo(AsnJenjangJabatan::class, 'asn_jenjang_jabatan_id'); + } + + public function golonganTerendah(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'terendah_id'); + } + + public function golonganTertinggi(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'tertinggi_id'); + } } diff --git a/src/Models/Instansi.php b/src/Models/Instansi.php index 645b08e..fa217b4 100644 --- a/src/Models/Instansi.php +++ b/src/Models/Instansi.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class Instansi extends Model @@ -31,4 +32,9 @@ class Instansi extends Model * @var array */ protected $guarded = []; + + public function lokasi(): BelongsTo + { + return $this->belongsTo(Lokasi::class, 'lokasiId'); + } } diff --git a/src/Models/JabatanFungsional.php b/src/Models/JabatanFungsional.php index c59fdb0..0150a7e 100644 --- a/src/Models/JabatanFungsional.php +++ b/src/Models/JabatanFungsional.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class JabatanFungsional extends Model @@ -31,4 +32,19 @@ class JabatanFungsional extends Model * @var array */ protected $guarded = []; + + public function golonganMin(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'min_gol_id'); + } + + public function golonganMax(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'max_gol_id'); + } + + public function kelompokJabatan(): BelongsTo + { + return $this->belongsTo(KelJabatan::class, 'kel_jabatan_id'); + } } diff --git a/src/Models/JabatanFungsionalUmum.php b/src/Models/JabatanFungsionalUmum.php index b02155f..ea5869a 100644 --- a/src/Models/JabatanFungsionalUmum.php +++ b/src/Models/JabatanFungsionalUmum.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class JabatanFungsionalUmum extends Model @@ -31,4 +32,9 @@ class JabatanFungsionalUmum extends Model * @var array */ protected $guarded = []; + + public function instansi(): BelongsTo + { + return $this->belongsTo(Instansi::class, 'instansi_id'); + } } diff --git a/src/Models/Kanreg.php b/src/Models/Kanreg.php index b008eee..5f6f5c5 100644 --- a/src/Models/Kanreg.php +++ b/src/Models/Kanreg.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class Kanreg extends Model @@ -31,4 +32,9 @@ class Kanreg extends Model * @var array */ protected $guarded = []; + + public function satuanKerja(): BelongsTo + { + return $this->belongsTo(SatuanKerja::class, 'satuanKerjaId'); + } } diff --git a/src/Models/Lokasi.php b/src/Models/Lokasi.php index 2d140f6..38a35a6 100644 --- a/src/Models/Lokasi.php +++ b/src/Models/Lokasi.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class Lokasi extends Model @@ -31,4 +32,14 @@ class Lokasi extends Model * @var array */ protected $guarded = []; + + public function kanreg(): BelongsTo + { + return $this->belongsTo(Kanreg::class, 'kanregId'); + } + + public function lokasi(): BelongsTo + { + return $this->belongsTo(Lokasi::class, 'lokasiId'); + } } diff --git a/src/Models/Pendidikan.php b/src/Models/Pendidikan.php index 7b657fe..fcbc6db 100644 --- a/src/Models/Pendidikan.php +++ b/src/Models/Pendidikan.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class Pendidikan extends Model @@ -31,4 +32,9 @@ class Pendidikan extends Model * @var array */ protected $guarded = []; + + public function tingkatPendidikan(): BelongsTo + { + return $this->belongsTo(TingkatPendidikan::class, 'tingkat_pendidikan_id'); + } } diff --git a/src/Models/SatuanKerja.php b/src/Models/SatuanKerja.php index 9126af5..4360aa2 100644 --- a/src/Models/SatuanKerja.php +++ b/src/Models/SatuanKerja.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class SatuanKerja extends Model @@ -31,4 +32,24 @@ class SatuanKerja extends Model * @var array */ protected $guarded = []; + + public function kanreg(): BelongsTo + { + return $this->belongsTo(Kanreg::class, 'kanregId'); + } + + public function lokasi(): BelongsTo + { + return $this->belongsTo(Lokasi::class, 'lokasiId'); + } + + public function instansi(): BelongsTo + { + return $this->belongsTo(Instansi::class, 'instansiId'); + } + + public function parent(): BelongsTo + { + return $this->belongsTo(SatuanKerja::class, 'parentId'); + } } diff --git a/src/Models/TingkatPendidikan.php b/src/Models/TingkatPendidikan.php index 98ea15e..40ea380 100644 --- a/src/Models/TingkatPendidikan.php +++ b/src/Models/TingkatPendidikan.php @@ -4,6 +4,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; +use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; class TingkatPendidikan extends Model @@ -31,4 +32,14 @@ class TingkatPendidikan extends Model * @var array */ protected $guarded = []; + + public function golongan(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'golongan_id'); + } + + public function golonganAwal(): BelongsTo + { + return $this->belongsTo(Golongan::class, 'golongan_awal_id'); + } }