281 lines
6.8 KiB
PHP
281 lines
6.8 KiB
PHP
<?php
|
|
// 1_Digunakan Untuk Nav Link Pada Side Bar Yg Aktif dan Tidak
|
|
$uri = service('uri');
|
|
$path = $uri->getPath();
|
|
$activeUrls = ['/admin', '/cs', '/analyst', '/doctor'];
|
|
?>
|
|
<!DOCTYPE html>
|
|
<html lang="id">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<?= $this->renderSection('title'); ?>
|
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/css/bootstrap.min.css" rel="stylesheet">
|
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.13.1/font/bootstrap-icons.min.css">
|
|
<link href="https://cdn.datatables.net/v/bs5/dt-2.3.4/r-3.0.7/datatables.min.css" rel="stylesheet" integrity="sha384-RaJlMsTv+nhuWA/3SQzc3dPVUOKfEb08YW4YZsaNK3UNFUhjvLkn/SwJEfKSavGD" crossorigin="anonymous">
|
|
<style>
|
|
table {
|
|
font-size: 0.7rem;
|
|
}
|
|
|
|
body {
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
#sidebar {
|
|
width: 200px;
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
height: 100vh;
|
|
background: #343a40;
|
|
color: #fff;
|
|
transition: all 0.3s;
|
|
overflow: hidden;
|
|
}
|
|
#sidebar.collapsed {
|
|
width: 70px;
|
|
}
|
|
#sidebar .nav-link {
|
|
color: #adb5bd;
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
transition: all 0.3s;
|
|
}
|
|
#sidebar.collapsed .nav-link span {
|
|
opacity: 0;
|
|
visibility: hidden;
|
|
width: 0;
|
|
}
|
|
#sidebar .nav-link.active {
|
|
background: #495057;
|
|
color: #fff;
|
|
}
|
|
#content {
|
|
margin-left: 200px;
|
|
transition: all 0.3s;
|
|
padding: 20px;
|
|
}
|
|
#content.fullwidth {
|
|
margin-left: 70px;
|
|
}
|
|
.toggle-btn {
|
|
position: fixed;
|
|
top: 15px;
|
|
left: 15px;
|
|
z-index: 999;
|
|
}
|
|
.main {
|
|
transition: margin-left 0.3s ease;
|
|
}
|
|
|
|
.main.shifted {
|
|
margin-left: 200px;
|
|
}
|
|
|
|
@media (max-width: 768px) {
|
|
.sidebar {
|
|
width: 150px;
|
|
}
|
|
|
|
.main.shifted {
|
|
margin-left: 150px;
|
|
}
|
|
}
|
|
|
|
|
|
/* Untuk Card Status Counter */
|
|
.status-card {
|
|
width: 123px;
|
|
/* lebar tetap */
|
|
height: 60px;
|
|
/* tinggi seragam */
|
|
border-radius: 8px;
|
|
background-color: #fff;
|
|
border : solid 1px #ddd ;
|
|
/* box-shadow: 0 3px 5px rgba(0, 0, 0, 0.08); */
|
|
transition: transform 0.15s ease, box-shadow 0.15s ease;
|
|
display: flex;
|
|
/* flex untuk isi card */
|
|
align-items: center;
|
|
/* tengah vertikal */
|
|
justify-content: center;
|
|
/* tengah horizontal */
|
|
flex-direction: column;
|
|
/* urut atas ke bawah */
|
|
}
|
|
|
|
.status-card:hover {
|
|
transform: translateY(-3px);
|
|
box-shadow: 0 6px 10px rgba(0, 0, 0, 0.2);
|
|
}
|
|
|
|
.status-icon {
|
|
font-size: 1.1rem;
|
|
}
|
|
|
|
.status-count {
|
|
font-weight: 700;
|
|
font-size: 1.1rem;
|
|
}
|
|
|
|
.status-label {
|
|
font-size: 0.75rem;
|
|
font-weight: 500;
|
|
white-space: nowrap;
|
|
/* biar teks tidak turun ke bawah */
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
/* kalau terlalu panjang, potong dengan "..." */
|
|
max-width: 100%;
|
|
/* biar rapih dalam box */
|
|
}
|
|
|
|
|
|
.dot {
|
|
height: 7px;
|
|
width: 7px;
|
|
border-radius: 50%;
|
|
display: inline-block;
|
|
margin: 0;
|
|
}
|
|
|
|
/* Untuk Cursor di Tabel */
|
|
.pointercol {
|
|
cursor: pointer;
|
|
}
|
|
|
|
/* 1 */
|
|
.Pend {
|
|
background-color: white;
|
|
}
|
|
|
|
/* 2 */
|
|
.PartColl {
|
|
background-color: #ff99aaaf !important;
|
|
}
|
|
|
|
/* 3 */
|
|
.Collected {
|
|
background-color: #d6303086 !important;
|
|
}
|
|
|
|
/* 4 */
|
|
.PartRecv {
|
|
background-color: #a0c0d9af !important;
|
|
}
|
|
|
|
/* 5 */
|
|
.Received {
|
|
background-color: #0985e39d !important;
|
|
}
|
|
|
|
/* 6 */
|
|
.Incomplete {
|
|
background-color: #fbff009a !important;
|
|
}
|
|
|
|
/* 7 */
|
|
.Final {
|
|
background-color: #90EE90 !important;
|
|
}
|
|
|
|
/* 8 */
|
|
.FinVerification {
|
|
background-color: #09ff00ab !important;
|
|
}
|
|
|
|
/* 9 */
|
|
.PenVerification {
|
|
background-color: #ee5a24c7 !important;
|
|
}
|
|
|
|
/* 10 */
|
|
.Suspend {
|
|
background-color: purple;
|
|
}
|
|
</style>
|
|
|
|
<?= $this->renderSection('css'); ?>
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<button class="btn btn-sm btn-secondary toggle-btn" id="toggleSidebar"> <i class="bi bi-list"></i> </button>
|
|
|
|
<div id="sidebar" class="collapsed">
|
|
<h5 class="p-3 text-center text-truncate"> <span class="sidebar-title">5Panda</span> </h5>
|
|
<nav class="nav flex-column px-2">
|
|
<a class="nav-link" href="<?=base_url('admin');?>"><i class="bi bi-house-door"></i> <span>Dashboard</span></a>
|
|
<a class="nav-link" href="<?=base_url('admin/user');?>"><i class="bi bi-people"></i> <span>Users</span></a>
|
|
<a class="nav-link" href="#"><i class="bi bi-graph-up"></i> <span>Reports</span></a>
|
|
<a class="nav-link" href="<?=base_url('logout');?>"><i class="bi bi-box-arrow-in-left"></i> <span>Log out</span></a>
|
|
</nav>
|
|
</div>
|
|
|
|
<div id="content" class="main p-1 fullwidth"> <?= $this->renderSection('content'); ?> </div>
|
|
|
|
<script>
|
|
console.log("Jangan Nakal Yaa😏😏😏");
|
|
</script>
|
|
|
|
<!-- Bootstrap 5 JS Bundle -->
|
|
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.8/dist/js/bootstrap.bundle.min.js"></script>
|
|
|
|
<!-- jQuery (Wajib untuk DataTables) -->
|
|
<script src="https://code.jquery.com/jquery-3.7.1.min.js"></script>
|
|
|
|
<!-- DataTables JS -->
|
|
<script src="https://cdn.datatables.net/v/bs5/dt-2.3.4/r-3.0.7/datatables.min.js" integrity="sha384-O4V7rOTTcSRflQBTMk8URAYWhGGEMgmmLFrqu3e83FQtze3vmndvrH3GcRdrfXRu" crossorigin="anonymous"></script>
|
|
<script src="https://cdn.datatables.net/2.0.8/js/dataTables.bootstrap5.min.js"></script>
|
|
|
|
<script>
|
|
const sidebar = document.getElementById('sidebar');
|
|
const main = document.getElementById('main');
|
|
|
|
// Datatable
|
|
$(document).ready(function () {
|
|
$('#datatables').DataTable({
|
|
order: [[0, 'asc'], [3, 'asc']],
|
|
paging: false,
|
|
scrollCollapse: true,
|
|
scrollY: '650px',
|
|
columnDefs: [{
|
|
className: 'text-center',
|
|
targets: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
|
|
}, // semua kolom di tengah
|
|
{
|
|
className: 'text-start',
|
|
targets: [12]
|
|
}
|
|
],
|
|
language: {
|
|
// search: "Cari:",
|
|
// lengthMenu: "Tampilkan _MENU_ data",
|
|
// info: "Menampilkan _START_ sampai _END_ dari _TOTAL_ data",
|
|
// paginate: {
|
|
// previous: "Sebelumnya",
|
|
// next: "Berikutnya"
|
|
// }
|
|
},
|
|
responsive: true,
|
|
});
|
|
|
|
$('#toggleSidebar').on('click', function () {
|
|
$('#sidebar').toggleClass('collapsed');
|
|
$('#content').toggleClass('fullwidth');
|
|
});
|
|
|
|
$('#sidebar .nav-link').on('click', function () {
|
|
$('#sidebar .nav-link').removeClass('active');
|
|
$(this).addClass('active');
|
|
});
|
|
|
|
});
|
|
</script>
|
|
<?= $this->renderSection('script'); ?>
|
|
</body>
|
|
|
|
</html>
|