297 lines
15 KiB
PHP
297 lines
15 KiB
PHP
<style>
|
|
.table th,
|
|
.table td {
|
|
padding: 8px;
|
|
}
|
|
|
|
table.dataTable tbody td {
|
|
padding: 4px 4px !important;
|
|
}
|
|
|
|
.col-12 {
|
|
|
|
max-width: 98% !important;
|
|
}
|
|
|
|
.dataTables_filter {
|
|
position: absolute;
|
|
}
|
|
|
|
.right-align-input {
|
|
text-align: right;
|
|
}
|
|
|
|
.addbtnStyle {
|
|
margin-left: 20px !important;
|
|
}
|
|
</style>
|
|
<style>
|
|
.table th:nth-child(1),
|
|
.table td:nth-child(1) {
|
|
max-width: 200px !important;
|
|
min-width: 100px !important;
|
|
overflow: hidden !important;
|
|
text-overflow: ellipsis !important;
|
|
white-space: nowrap !important;
|
|
}
|
|
|
|
#scroll-horizontal-datatable tbody tr:hover {
|
|
background-color: #e0e0e0;
|
|
}
|
|
|
|
|
|
</style>
|
|
|
|
|
|
|
|
<div class="col-12">
|
|
<div class="card">
|
|
<div class="card-body">
|
|
<div class="row" style="padding-bottom: 10px;">
|
|
<div class="col-6" style="align-self: center;">
|
|
<h4 style="position: relative;">Claim List </h4>
|
|
</div>
|
|
|
|
</div>
|
|
<div class="table-responsive">
|
|
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
|
|
<thead class="bg-light">
|
|
<tr>
|
|
<th>Status</th>
|
|
<th>Policy Type</th>
|
|
<th>Claim number</th>
|
|
<th>TPA ID</th>
|
|
<th>Emp ID</th>
|
|
<th>Emp name</th>
|
|
<th>Insured Name</th>
|
|
<th>Corporate name</th>
|
|
|
|
<th style="display: none;">ACM</th>
|
|
<th style="display: none;">Insurer</th>
|
|
<th style="display: none;">TPA</th>
|
|
<th style="display: none;">Policy No</th>
|
|
<th style="display: none;">Priority</th>
|
|
<th style="display: none;">Relationship</th>
|
|
<th style="display: none;">Emp Mobile</th>
|
|
<th style="display: none;">Emp Email</th>
|
|
<th style="display: none;">Emp Personal Email</th>
|
|
<th style="display: none;">Mode of Intimation</th>
|
|
<th style="display: none;">Claim Type</th>
|
|
<th style="display: none;">Hospital Name</th>
|
|
<th style="display: none;">DOA</th>
|
|
<th style="display: none;">DOD</th>
|
|
<th style="display: none;">Claim Amount</th>
|
|
<th style="display: none;">POD No.</th>
|
|
<th style="display: none;">Date of Join</th>
|
|
<th style="display: none;">Date of Inception</th>
|
|
<th style="display: none;">DOB</th>
|
|
<th style="display: none;">Date of Accident</th>
|
|
<th style="display: none;">Date of Death</th>
|
|
<th style="display: none;">Date of Intimate</th>
|
|
<th style="display: none;">Sum Insured</th>
|
|
<th style="display: none;">Raised Date</th>
|
|
<th style="display: none;">Registration Date</th>
|
|
<th style="display: none;">Query Received Date</th>
|
|
<th style="display: none;">Denial Date</th>
|
|
<th style="display: none;">Approved Date</th>
|
|
<th style="display: none;">Settled Date</th>
|
|
<th style="display: none;">Denial Reason</th>
|
|
<th style="display: none;">Approved Letter</th>
|
|
<th style="display: none;">Approved Amount</th>
|
|
<th style="display: none;">UTR Details</th>
|
|
<th style="display: none;">Settle Letter</th>
|
|
<th style="display: none;">Return Remark</th>
|
|
<th style="display: none;">Cancel Remark</th>
|
|
<th style="display: none;">AWB No. and Courier Name</th>
|
|
<th style="display: none;">Non ID Reason</th>
|
|
<th style="display: none;">Payment Initiate Date</th>
|
|
<th style="display: none;">Approved Description</th>
|
|
|
|
|
|
<th>TAT</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<?php if (isset($ticket_data)) { ?>
|
|
<?php foreach($ticket_data as $index => $row){ ?>
|
|
<tr onclick="viewTicket(<?php echo $row['id']; ?>)" style="cursor: pointer;">
|
|
|
|
<td data-toggle="tooltip" data-placement="top"
|
|
|
|
|
|
title=" <?php
|
|
if ($row['claim_status_id'] == 8) {
|
|
if ($row['is_head_approved'] == 0) {
|
|
echo 'Waiting for approvel';
|
|
} elseif ($row['is_head_approved'] == 1) {
|
|
echo 'Rejection approved';
|
|
} elseif ($row['is_head_approved'] == 2) {
|
|
echo 'Rejection not approved';
|
|
} else {
|
|
echo $row['status'];
|
|
}
|
|
} else {
|
|
echo $row['status'];
|
|
}
|
|
?>">
|
|
|
|
|
|
<span class="status-tooltip">
|
|
<?php
|
|
if (in_array($row['claim_status_id'],[8,23,33,43])) {
|
|
if ($row['is_head_approved'] == 0) {
|
|
echo $row['status'] . ' <i class="fa fa-exclamation-triangle" style="color:#cece00;" aria-hidden="true"></i>';
|
|
} elseif ($row['is_head_approved'] == 1) {
|
|
echo $row['status'] . ' <i class="fa fa-check-circle" style="color:green;" aria-hidden="true"></i>';
|
|
} elseif ($row['is_head_approved'] == 2) {
|
|
echo $row['status'] . ' <i class="fa fa-times-circle" style="color:red;" aria-hidden="true"></i>';
|
|
} else {
|
|
echo $row['status'];
|
|
}
|
|
} else {
|
|
echo $row['status'];
|
|
}
|
|
?>
|
|
</span>
|
|
</td>
|
|
|
|
<td><?php echo str_replace("Claim-", "", $ticket_type[$row['ticket_type_id']] ?? ""); ?></td>
|
|
<td><?php echo $row['claim_no']; ?></td>
|
|
<td><?php echo $row['tpa_no']; ?></td>
|
|
<td><?php echo $row['emp_code']; ?></td>
|
|
<td><?php echo $row['emp_name']; ?></td>
|
|
<td><?php echo $row['insured_name']; ?></td>
|
|
<td><?php echo $row['short_name']; ?></td>
|
|
|
|
<td style="display: none;"><?php echo $row['acm_name']; ?></td>
|
|
<td style="display: none;"><?php echo $row['insurer_name']; ?></td>
|
|
<td style="display: none;"><?php echo $row['tpa_name']; ?></td>
|
|
<td style="display: none;"><?php echo $row['policy_no']; ?></td>
|
|
<td style="display: none;"><?php echo isset($priorityType[$row['priority'] ?? 0]) ? $priorityType[$row['priority'] ?? 0] : ''; ?></td>
|
|
<td style="display: none;"><?php echo $row['relationship']; ?></td>
|
|
<td style="display: none;"><?php echo $row['emp_mobile']; ?></td>
|
|
<td style="display: none;"><?php echo $row['emp_mail']; ?></td>
|
|
<td style="display: none;"><?php echo $row['emp_personal_mail']; ?></td>
|
|
<td style="display: none;"><?php echo isset($modeOFIntimate[$row['mode_of_intimation'] ?? '']) ? $modeOFIntimate[$row['mode_of_intimation']] : ''; ?></td>
|
|
<td style="display: none;">
|
|
<?php
|
|
$typeId = $row['ticket_type_id'] ?? 0;
|
|
$claimKey = $row['claim_type'] ?? '';
|
|
if ($typeId == 1) {
|
|
echo isset($claimType[1][$claimKey]) ? $claimType[1][$claimKey] : '';
|
|
} else {
|
|
echo isset($claimType[2][$claimKey]) ? $claimType[2][$claimKey] : '';
|
|
}
|
|
?>
|
|
</td>
|
|
<td style="display: none;"><?php echo $row['hospital_name']; ?></td>
|
|
<td style="display: none;"><?php echo change_date_format($row['doa'], null, 'd-m-Y'); ?></td>
|
|
<td style="display: none;"><?php echo $row['dod']; ?></td>
|
|
<td style="display: none;"><?php echo $row['claim_amount']; ?></td>
|
|
<td style="display: none;"><?php echo $row['pod_no']; ?></td>
|
|
<td style="display: none;"><?php echo $row['date_of_join']; ?></td>
|
|
<td style="display: none;"><?php echo $row['date_of_incep']; ?></td>
|
|
<td style="display: none;"><?php echo $row['dob']; ?></td>
|
|
<td style="display: none;"><?php echo $row['date_of_accident']; ?></td>
|
|
<td style="display: none;"><?php echo $row['date_of_death']; ?></td>
|
|
<td style="display: none;"><?php echo $row['date_of_intimat']; ?></td>
|
|
<td style="display: none;"><?php echo $row['si_amt']; ?></td>
|
|
<td style="display: none;"><?php echo $row['raised_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['registration_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['query_received_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['denial_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['approved_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['settled_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['denial_reason']; ?></td>
|
|
<td style="display: none;"><?php echo $row['approved_letter']; ?></td>
|
|
<td style="display: none;"><?php echo $row['approved_amount']; ?></td>
|
|
<td style="display: none;"><?php echo $row['utr_details']; ?></td>
|
|
<td style="display: none;"><?php echo $row['settle_letter']; ?></td>
|
|
<td style="display: none;"><?php echo $row['return_remark']; ?></td>
|
|
<td style="display: none;"><?php echo $row['cancel_remark']; ?></td>
|
|
<td style="display: none;"><?php echo $row['awb_no_courier_name']; ?></td>
|
|
<td style="display: none;"><?php echo $row['non_id_reason']; ?></td>
|
|
<td style="display: none;"><?php echo $row['pay_initiate_date']; ?></td>
|
|
<td style="display: none;"><?php echo $row['approved_description']; ?></td>
|
|
|
|
|
|
<td><?php echo $row['tat']; ?></td>
|
|
</tr>
|
|
<?php } ?>
|
|
<?php } ?>
|
|
</tbody>
|
|
</table>
|
|
|
|
<div>
|
|
</div>
|
|
</div>
|
|
</div><!-- end col -->
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
<!-------------------------------------------------------------------------------------------------->
|
|
|
|
<script>
|
|
$(document).ready(function() {
|
|
$('[data-toggle="tooltip"]').tooltip();
|
|
});
|
|
|
|
// Datatable document ready
|
|
$(document).ready(function() {
|
|
|
|
var ticketsTable = $('#scroll-horizontal-datatable');
|
|
|
|
if (ticketsTable.length) {
|
|
|
|
ticketsTable.DataTable({
|
|
scrollX: true,
|
|
dom: "<'row'<'col-sm-6'f><'col-sm-6 text-right'B>>" + // Filter left, buttons right
|
|
"<'row'<'col-sm-12'tr>>" +
|
|
"<'row'<'col-sm-5'i><'col-sm-7'p>>", // Pagination at the bottom, without page length selector
|
|
buttons: [{
|
|
extend: 'csv',
|
|
text: 'CSV',
|
|
title: 'Claim-List',
|
|
},
|
|
{
|
|
extend: 'excel',
|
|
text: 'Excel',
|
|
title: 'claim-List',
|
|
exportOptions: {
|
|
orthogonal: 'sort'
|
|
},
|
|
},
|
|
{
|
|
text: 'New Claim',
|
|
className: 'buttons-html5 addbtnStyle',
|
|
action: function(e, dt, node, config) {
|
|
openTicketTypeAskModal()
|
|
}
|
|
}
|
|
],
|
|
language: {
|
|
search: "_INPUT_",
|
|
searchPlaceholder: "Search..."
|
|
},
|
|
paging: true, // Enable pagination
|
|
pageLength: 25, // Set default number of rows per page (optional)
|
|
ordering: false,
|
|
});
|
|
} else {
|
|
console.error("Table atet found.");
|
|
}
|
|
});
|
|
|
|
function viewTicket(ticket_id){
|
|
|
|
$('.loader').fadeIn();
|
|
$('.loader-mask').fadeIn();
|
|
|
|
let url = '<?= base_url('ticket/view/'); ?>' + ticket_id
|
|
window.location.href = url
|
|
|
|
}
|
|
|
|
</script>
|