This commit is contained in:
Dwi Swandhana
2026-03-11 14:19:37 +07:00
parent 3eb845b503
commit e03381c6aa
2 changed files with 50 additions and 44 deletions
@@ -125,7 +125,10 @@
@foreach($detail as $r)
@php
$isPrinted = !empty($r['ppdsjunior2']) && $r['ppdsjunior2'] != '0';
$statusValue = trim((string)($r['status'] ?? '-'));
$statusValue = trim((string)($r['status'] ?? ''));
if ($statusValue === '') {
$statusValue = '-';
}
$petugas = '';
if ($r['nmppdsmiddle2'] != '') {
$petugas = $r['nmppdsmiddle2'];
@@ -359,15 +362,13 @@
if (!table || !filterStatus) {
return;
}
var statusSet = new Set();
table.querySelectorAll('tbody tr').forEach(function(row) {
var statusText = (row.children[10] ? row.children[10].innerText : '').trim();
if (statusText !== '') {
statusSet.add(statusText);
}
});
while (filterStatus.options.length > 1) {
filterStatus.remove(1);
}
Array.from(statusSet).sort().forEach(function(status) {
// Status yang valid untuk rekap penerimaan sample
var allowed = ['-', 'Pemeriksaan awal', 'Pemeriksaan Sampel', 'Penerimaan Sampel'];
allowed.forEach(function(status) {
var opt = document.createElement('option');
opt.value = status.toLowerCase();
opt.textContent = 'Status: ' + status;