Diagnosis UI: radiology labels, sub-div navigation, search bar layout, back button fix
This commit is contained in:
parent
2b6b097cca
commit
174484eae2
|
|
@ -158,6 +158,11 @@ $editReason = trim((string) ($edit_reason ?? ''));
|
|||
const invoiceId = document.getElementById('invoice_id') ? document.getElementById('invoice_id').value : '';
|
||||
const labType = document.getElementById('lab_type') ? document.getElementById('lab_type').value : '';
|
||||
|
||||
if (typeof load_form_div === 'function' && invoiceId && labType) {
|
||||
load_form_div(baseUrl + 'diagnosis/select-lab-invoice/' + invoiceId + '/' + labType, 'searchresult', 'Diagnosis');
|
||||
return;
|
||||
}
|
||||
|
||||
if (typeof load_form === 'function' && invoiceId && labType) {
|
||||
load_form(baseUrl + 'diagnosis/select-lab-invoice/' + invoiceId + '/' + labType, 'Diagnosis');
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -6,6 +6,11 @@ $currentLabType = (int) ($lab_type ?? $labType ?? 0);
|
|||
$isRadiologyFlow = !in_array($currentLabType, [5, 30], true);
|
||||
$flowTitle = $isRadiologyFlow ? 'Imaging Worklist' : 'Pathology Worklist';
|
||||
$statusPendingLabel = $isRadiologyFlow ? 'Report Pending' : 'Data Pending';
|
||||
$samplePendingLabel = $isRadiologyFlow ? 'Scan Pending' : 'Sample Collection Pending';
|
||||
$sampleActionLabel = $isRadiologyFlow ? 'Start Scan' : 'Sample Collection';
|
||||
$sampleActionIcon = $isRadiologyFlow ? 'bi-camera-reels' : 'bi-flask';
|
||||
$testNoPlaceholder = $isRadiologyFlow ? 'Imaging Test No.' : 'Lab Test No.';
|
||||
$updateTestNoLabel = $isRadiologyFlow ? 'Update Test No.' : 'Update Lab No.';
|
||||
$printTemplates = $print_templates ?? [];
|
||||
|
||||
if (!empty($lab_invoice_request) && count($lab_invoice_request) > 0) {
|
||||
|
|
@ -49,9 +54,9 @@ if (!empty($lab_invoice_request) && count($lab_invoice_request) > 0) {
|
|||
<div class="col-md-5 col-sm-6">
|
||||
<div class="input-group input-group-sm">
|
||||
<input type="hidden" id="lab_req_id" name="lab_req_id" value="<?php echo htmlspecialchars($labReqId); ?>">
|
||||
<input type="text" class="form-control" id="inputLabNo" name="inputLabNo" placeholder="Lab Test No."
|
||||
<input type="text" class="form-control" id="inputLabNo" name="inputLabNo" placeholder="<?php echo htmlspecialchars($testNoPlaceholder); ?>"
|
||||
value="<?php echo htmlspecialchars($labTestNo); ?>">
|
||||
<button type="button" class="btn btn-info" onclick="updateLabNo()">Update Lab No.</button>
|
||||
<button type="button" class="btn btn-info" onclick="updateLabNo()"><?php echo htmlspecialchars($updateTestNoLabel); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -66,7 +71,7 @@ if (!empty($lab_invoice_request) && count($lab_invoice_request) > 0) {
|
|||
<div class="fw-semibold"><?php echo htmlspecialchars($test->item_name ?? ''); ?></div>
|
||||
|
||||
<?php if (empty($test->check_sample) || $test->check_sample < 1): ?>
|
||||
<span class="badge bg-danger">Sample Collection Pending</span>
|
||||
<span class="badge bg-danger"><?php echo htmlspecialchars($samplePendingLabel); ?></span>
|
||||
<?php else: ?>
|
||||
<?php if ($status === 0): ?>
|
||||
<span class="badge bg-warning text-dark"><?php echo htmlspecialchars($statusPendingLabel); ?></span>
|
||||
|
|
@ -81,7 +86,7 @@ if (!empty($lab_invoice_request) && count($lab_invoice_request) > 0) {
|
|||
<?php if (empty($test->check_sample) || $test->check_sample < 1): ?>
|
||||
<button type="button" class="btn btn-danger btn-sm"
|
||||
onclick="updateSampleCollection(<?php echo htmlspecialchars($test->test_id ?? '0'); ?>, '<?php echo htmlspecialchars($test->item_name ?? ''); ?>')">
|
||||
<i class="bi bi-flask"></i> Sample Collection
|
||||
<i class="bi <?php echo htmlspecialchars($sampleActionIcon); ?>"></i> <?php echo htmlspecialchars($sampleActionLabel); ?>
|
||||
</button>
|
||||
<?php else: ?>
|
||||
<div class="d-flex flex-wrap align-items-center gap-3 mb-2">
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<div class="card">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">Diagnosis Report List</h5>
|
||||
<div class="card-body" style="padding-top: 12px;">
|
||||
<h5 class="card-title" style="padding-top: 0px;padding-bottom: 0px;">Diagnosis Report List</h5>
|
||||
|
||||
<?php if (empty($labreport_preprocess)): ?>
|
||||
<div class="alert alert-info alert-dismissible fade show" role="alert">
|
||||
|
|
@ -89,7 +89,7 @@
|
|||
<div class="modal-dialog modal-lg">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="radiologyLabel">Radiology Report</h5>
|
||||
<h5 class="modal-title" id="radiologyLabel" style="padding-top: 0px;padding-bottom: 0px;">Radiology Report</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
|
|
@ -105,6 +105,6 @@
|
|||
function show_record(inv_id) {
|
||||
var labType = document.getElementById('lab_type') ? document.getElementById('lab_type').value : 1;
|
||||
var url = '<?= base_url('diagnosis/select-lab-invoice') ?>/' + inv_id + '/' + labType;
|
||||
load_form(url, 'Radiology Invoice Details');
|
||||
load_form_div(url, 'searchresult', 'Radiology Invoice Details');
|
||||
}
|
||||
</script>
|
||||
|
|
|
|||
|
|
@ -1,60 +1,44 @@
|
|||
<input type="hidden" id="lab_type" name="lab_type" value="<?= esc($lab_type) ?>" />
|
||||
|
||||
<div class="pagetitle">
|
||||
<h1><?= esc($lab_type_name) ?></h1>
|
||||
<nav>
|
||||
<ol class="breadcrumb">
|
||||
<li class="breadcrumb-item"><a href="<?= base_url('dashboard') ?>">Home</a></li>
|
||||
<li class="breadcrumb-item"><a href="javascript:load_form('<?= base_url('diagnosis') ?>','Diagnosis');">Diagnosis</a></li>
|
||||
<li class="breadcrumb-item active"><?= esc($lab_type_name) ?></li>
|
||||
</ol>
|
||||
</nav>
|
||||
</div>
|
||||
<style>
|
||||
.diag-search-strip .card-body {
|
||||
padding: 12px;
|
||||
}
|
||||
.diag-search-strip .input-group .btn {
|
||||
min-width: 132px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<section class="section">
|
||||
<div class="card">
|
||||
<div class="card diag-search-strip">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">Search</h5>
|
||||
|
||||
<div class="row g-3">
|
||||
<div class="col-md-3">
|
||||
<div class="row g-2 align-items-center">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input class="form-control" type="text" id="txtsearch" name="txtsearch" placeholder="Invoice / UHID / Phone">
|
||||
<input class="form-control" type="text" id="txtsearch" name="txtsearch" placeholder="Invoice Last 6 digit ,UHID,Phone No.">
|
||||
<button type="button" class="btn btn-primary" id="btn_search">
|
||||
<i class="bi bi-search"></i> Search
|
||||
Search Invoice
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input class="form-control" type="text" id="txtsearch_srno" name="txtsearch_srno" placeholder="Daily Serial No.">
|
||||
<button type="button" class="btn btn-info" id="btn_srno">
|
||||
<i class="bi bi-search"></i> Sr. No.
|
||||
Search by Sr. No.
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input class="form-control" type="text" id="txtsearch_labno" name="txtsearch_labno" placeholder="Lab No.">
|
||||
<button type="button" class="btn btn-success" id="btn_labno">
|
||||
<i class="bi bi-search"></i> Lab No.
|
||||
Search By Lab No.
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<?php if ($lab_type == 5): ?>
|
||||
<a href="javascript:void(0);" class="btn btn-secondary">
|
||||
<i class="bi bi-file-earmark-text"></i> Template
|
||||
</a>
|
||||
<?php else: ?>
|
||||
<a href="javascript:void(0);" class="btn btn-secondary">
|
||||
<i class="bi bi-file-earmark-text"></i> Template
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -200,7 +184,10 @@ $(document).ready(function() {
|
|||
window.selectPathoology = function(invoiceId) {
|
||||
var labType = $('#lab_type').val();
|
||||
var url = '<?= base_url('diagnosis/select-lab-invoice') ?>/' + invoiceId + '/' + labType;
|
||||
load_form(url, 'Pathology Invoice Details');
|
||||
load_form_div(url, 'searchresult', 'Pathology Invoice Details');
|
||||
};
|
||||
|
||||
// Keep old HMS behavior: load recent items immediately.
|
||||
performSearch();
|
||||
});
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user