🔧 refactor(laporan): kontrol akses role, optimasi query, dan perbaikan UI
- Tambah role `pemohon-ao` & `pemohon-eo` untuk upload lampiran di LampiranDokumen.php - Implementasi kontrol akses role di lampiran-dokumen.blade.php & laporan/index.blade.php (logika khusus nilai_liquidasi) - Modifikasi query di LaporanController.php: hapus filter approval_eo_at & optimasi kondisi WHERE - Perbaikan formatting query dengan indentasi lebih rapi & maintainable - Standardisasi urutan class CSS di beberapa Blade (activity/index, penilaian/otorisator/index-sla & index) - Pisahkan logika generateLaporanButton jadi function terpisah di laporan/index.blade.php - Perbaikan tampilan tombol laporan berbasis role + cleanup baris kosong & indentasi - Konsistensi UI/UX: responsive design lebih baik, interface clean & styling konsisten dengan Tailwind - Tingkatkan security & maintainability: granular role access, query lebih efisien, code lebih terstruktur
This commit is contained in:
@@ -5,12 +5,12 @@
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
<div class="card border border-agi-100 pb-2.5">
|
||||
<div class=" card-grid min-w-full" data-datatable="false" data-datatable-page-size="10"
|
||||
<div class="grid gap-5 mx-auto w-full lg:gap-7.5">
|
||||
<div class="pb-2.5 border card border-agi-100">
|
||||
<div class="min-w-full card-grid" data-datatable="false" data-datatable-page-size="10"
|
||||
data-datatable-state-save="false" id="permohonan-table"
|
||||
data-api-url="{{ route('otorisator.sla.datatables') }}">
|
||||
<div class="card-header bg-agi-50 py-5 flex-wrap">
|
||||
<div class="flex-wrap py-5 card-header bg-agi-50">
|
||||
<h3 class="card-title">
|
||||
Daftar {{ $header }}
|
||||
</h3>
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm"
|
||||
<table class="table text-sm font-medium text-gray-700 align-middle table-auto table-border"
|
||||
data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
@@ -81,13 +81,13 @@
|
||||
</table>
|
||||
</div>
|
||||
<div
|
||||
class="card-footer justify-center md:justify-between flex-col md:flex-row gap-3 text-gray-600 text-2sm font-medium">
|
||||
<div class="flex items-center gap-2">
|
||||
class="flex-col gap-3 justify-center font-medium text-gray-600 card-footer md:justify-between md:flex-row text-2sm">
|
||||
<div class="flex gap-2 items-center">
|
||||
Show
|
||||
<select class="select select-sm w-16" data-datatable-size="true" name="perpage"> </select> per
|
||||
<select class="w-16 select select-sm" data-datatable-size="true" name="perpage"> </select> per
|
||||
page
|
||||
</div>
|
||||
<div class="flex items-center gap-4">
|
||||
<div class="flex gap-4 items-center">
|
||||
<span data-datatable-info="true"> </span>
|
||||
<div class="pagination" data-datatable-pagination="true">
|
||||
</div>
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
<div class="card border border-agi-100 card-grid min-w-full" data-datatable="false" data-datatable-page-size="10"
|
||||
<div class="grid gap-5 mx-auto w-full lg:gap-7.5">
|
||||
<div class="min-w-full border card border-agi-100 card-grid" data-datatable="false" data-datatable-page-size="10"
|
||||
data-datatable-state-save="false" id="permohonan-table"
|
||||
data-api-url="{{ route('otorisator.datatables', ['otorisator' => $header]) }}">
|
||||
<div class="flex-wrap py-5 card-header bg-agi-50">
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
@if ($header == 'Pelaporan')
|
||||
<div class="flex">
|
||||
<select class="select select-sm w-28" id="region">
|
||||
<select class="w-28 select select-sm" id="region">
|
||||
<option value="">
|
||||
Pilih Region
|
||||
</option>
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm"
|
||||
<table class="table text-sm font-medium text-gray-700 align-middle table-auto table-border"
|
||||
data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
@@ -112,13 +112,13 @@
|
||||
</table>
|
||||
</div>
|
||||
<div
|
||||
class="flex-col justify-center gap-3 font-medium text-gray-600 card-footer md:justify-between md:flex-row text-2sm">
|
||||
<div class="flex items-center gap-2">
|
||||
class="flex-col gap-3 justify-center font-medium text-gray-600 card-footer md:justify-between md:flex-row text-2sm">
|
||||
<div class="flex gap-2 items-center">
|
||||
Show
|
||||
<select class="w-16 select select-sm" data-datatable-size="true" name="perpage"> </select> per
|
||||
page
|
||||
</div>
|
||||
<div class="flex items-center gap-4">
|
||||
<div class="flex gap-4 items-center">
|
||||
<span data-datatable-info="true"> </span>
|
||||
<div class="pagination" data-datatable-pagination="true">
|
||||
</div>
|
||||
@@ -234,7 +234,7 @@
|
||||
title: 'Jenis laporan',
|
||||
render: (item, data) => {
|
||||
if (data.penilai.type_penilai) {
|
||||
return `<span class="text-md font-bold capitalize">${data.penilai.type_penilai}</span>`;
|
||||
return `<span class="font-bold capitalize text-md">${data.penilai.type_penilai}</span>`;
|
||||
}
|
||||
return '';
|
||||
},
|
||||
@@ -285,7 +285,7 @@
|
||||
const isAdmin = userRoles.includes('administrator');
|
||||
|
||||
let buttons = `
|
||||
<div class="flex justify-center flex-nowrap">
|
||||
<div class="flex flex-nowrap justify-center">
|
||||
<a class="btn btn-sm btn-icon btn-clear btn-warning" href="otorisator/show/${data.id}/${dataHeader}">
|
||||
<i class="ki-outline ki-eye"></i>
|
||||
</a>
|
||||
|
||||
Reference in New Issue
Block a user