MERGE_UAT_RFQEB_INS_MAIL_NOTIDY&UI&SINGLE_FILE_

This commit is contained in:
Ubuntu 2025-08-30 18:22:13 +05:30
commit b5d2b458be
121 changed files with 4743 additions and 904 deletions

View File

@ -369,6 +369,7 @@ $routes->group("/util", ["filter" => "authMVC"], function ($routes) {
$routes->get('getPolicyTypeFields', 'LeadsController::getPolicyTypeFields');
$routes->get('removeMultiFile', 'LeadsController::removeMultiFile');
$routes->get('removeInstallments', 'LeadsController::removeInstallments');
$routes->get('getLeadEmailHistory/(:any)', 'LeadsController::getLeadEmailHistory/$1');
$routes->get('viewHrAccessData', 'ClientController::viewHrAccessData');
$routes->post('saveHrAccessData', 'ClientController::saveHrAccessData');
$routes->get('removeLevelContacts', 'ClientController::removeLevelContacts');
@ -452,7 +453,6 @@ $routes->get('cli/sendZeptoMail', 'MasterController::testZeptoSMTP');
$routes->cli('cli/processjob', 'JobWorker::processJob');
$routes->cli('cli/processjobs', 'JobWorker::processJobs');
$routes->cli('cli/sendMailWithAutoQuery','TicketController::sendMailWithAutoQuery');
$routes->get("processjob", "JobWorker::processJob");
$routes->cli('cli/new_gmail_token', 'MasterController::generateNewGmailAPIToken');
@ -466,6 +466,10 @@ $routes->cli('cli/new_gdrive_token', 'GoogleDriveController::generateNewGoogleDr
$routes->cli('cli/enrollOpendAndClose', 'DashboardController::updatePolicyEnrollmentStatus');
$routes->cli("cli/sendCroneRemainderMail", "DashboardController::sendCroneRemainderMail");
$routes->cli('cli/update-emp-policy-status', 'ClientController::updateEmpAndPolicyStatus');
$routes->cli('cli/update-emp-policy-status', 'ClientController::updateEmpAndPolicyStatus');
$routes->cli('cli/insurerRFQRemainder', 'LeadsController::remainderForQcr');
$routes->cli('cli/sendMailWithAutoQuery','TicketController::sendMailWithAutoQuery');
//Employee login api's
$routes->post("/employeeRest/verifyEmployeeNumber", "RestAuthenticationController::verifyEmployeeWithMobileNumber");
@ -562,6 +566,8 @@ $routes->group("employeeRest", ["filter" => "authJWT"], function ($routes) {
$routes->get("ticketList", "ThzController::ticketList");
$routes->post("ticketConversationSave", "ThzController::ticketConversationSave");
$routes->get("ticketConversationList", "ThzController::ticketConversationList");
$routes->get("ticketHistoryList", "ThzController::ticketHistoryList");
$routes->match(['get','post','put'], 'ticketType', 'ThzController::ticketType');
$routes->get("hrFileList", "EmployeeRestController::hrFileList");
$routes->get("hrFileUploadMasters", "EmployeeRestController::hrFileUploadMasters");
@ -660,4 +666,12 @@ $routes->get("ticketList", "ThzController::ticketList");
$routes->post("ticketConversationSave", "ThzController::ticketConversationSave");
$routes->get("ticketConversationList", "ThzController::ticketConversationList");
$routes->post('ticketAutoFetchDetails',"ThzController::ticketAutoFetchDetails");
// $routes->match(['get','post','put'], 'ticketType', 'ThzController::ticketType');
$routes->match(['get','post','put'], 'ticketType', 'ThzController::ticketType');
$routes->get("ticketHistoryList", "ThzController::ticketHistoryList");
//for testing
$routes->group('test', function($routes) {
$routes->post('api/saveForm', 'TestingController::saveForm');
$routes->get('insurerRFQRemainder', 'LeadsController::remainderForQcr');
});

View File

@ -184,7 +184,7 @@ class ClientController extends AdminController
public function testMailAttachments($email = 'venkateshraman786@gmail.com')
{
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table data-custom-table-css="table" class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
// $attachments = [
// ["filePath" => ROOTPATH."public/sample_excel/sample_addition.xls","fileName" => "sample_addition.xls"],
@ -5060,9 +5060,10 @@ class ClientController extends AdminController
// ---------- TICKET SERVICE CONTROLLER --------------------------------------------------------------------------------
$ticketServiceController = new TicketServiceController();
// $response = $ticketServiceController->claimDumpExcelFileFormatValidation(["file_id" => 3]);
// $response = $ticketServiceController->claimDumpExcelFileDataValidation(["file_id" => 3]);
// $response = $ticketServiceController->claimDumpOnBoardProcess(["file_id" => 3]);
// $response = $ticketServiceController->claimDumpExcelFileFormatValidation(["file_id" => 34]);
// $response = $ticketServiceController->claimDumpExcelFileDataValidation(["file_id" => 34]);
// $response = $ticketServiceController->getClaimExcelErrorData(["file_id" => 41]);
// $response = $ticketServiceController->claimDumpOnBoardProcess(["file_id" => 17]);
// $response = $ticketServiceController->extractExcelData("claims_dump_form_client.xlsx");
// dd($response);
@ -5079,8 +5080,16 @@ class ClientController extends AdminController
// $res = $empServiceController->employeesCorrectionProcess(['file_id' => '1681']);
// dd( $res);
// $EmployeeMultiEventServiceController = new EmployeeMultiEventServiceController();
// $res = $EmployeeMultiEventServiceController->constructMultiEventData(['file_id' => '1056']);
$EmployeeMultiEventServiceController = new EmployeeMultiEventServiceController();
// $res = $EmployeeMultiEventServiceController->constructMultiEventData(['file_id' => '1069']);
// $res = $EmployeeMultiEventServiceController->excelMultieventFileFormateValidation(['file_id' => '1084']);
// $res = $EmployeeMultiEventServiceController->excelMultieventFileDataValidation(['file_id' => '1069']);
// $res = $EmployeeMultiEventServiceController->excelMultieventFileOnBoard(['file_id' => '1069']);
// dd($res);
// $res = $EmployeeMultiEventServiceController->getExcelErrorData(1069, $res);
// $res['file_id'] = 1069;
// echo view('excel_errors', $res);
// dd($res);
// ---------- POLICY TRANSACTION CONTROLLER --------------------------------------------------------------------------------
@ -5454,10 +5463,21 @@ class ClientController extends AdminController
}
}
public function getTheEmpDataForClaimSearchByMobile($param, $type = 'mobile', $client_policy_id = null, $client_id = null)
public function getTheEmpDataForClaimSearchByMobile($param, $type = 'mobile', $client_policy_id = null, $client_id = null, $ticket_type_id = null)
{
$field_name = 'employees.' . $type;
$policy_type_id = [];
if($ticket_type_id == 1){
$policy_type_id = [2, 3, 4, 5];
}else if($ticket_type_id == 2){
$policy_type_id = [1];
}else if($ticket_type_id == 3){
$policy_type_id = [6];
}else if($ticket_type_id == 4){
$policy_type_id = [7];
}
// Construct the base query
$query = $this->clientPolicyModel
->select("
@ -5481,7 +5501,7 @@ class ClientController extends AdminController
->join('insurers', 'client_policy.insurer_id = insurers.id')
->join('tpa', 'client_policy.tpa_id = tpa.id', 'left')
->join('employees', 'clients.id = employees.client_id')
->join('employee_polices', 'employees.id = employee_polices.employee_id')
->join('employee_polices', 'employees.id = employee_polices.employee_id AND client_policy.id = employee_polices.client_policy_id')
->where('client_policy.is_active', 1)
->where('insurers.is_active', 1)
->where('tpa.is_active', 1)
@ -5499,6 +5519,10 @@ class ClientController extends AdminController
if (!empty($client_policy_id)) {
$query->where('employee_polices.client_policy_id', $client_policy_id);
}
if($policy_type_id != null){
$query->whereIn('client_policy.policy_type_id', $policy_type_id);
}
$query->groupBy('employees.id')
->orderBy('employees.id', 'DESC');
@ -6612,268 +6636,6 @@ class ClientController extends AdminController
// ------------------- DEMO CLIENT FUNCTION --------------------------------------------------------------------------------
// public function wipeDemoClient()
// {
// // $this->myLogger->logme('error', "Wipe Demo Client function called");
// $this->myLogger->logme('error', "Wipe Demo Client function called"); // Red text
// $this->myLogger->logme('error', "Wipe Demo client Payload : " . json_encode($this->request->getPost() ?? []));
// $client_id = $this->request->getPost('client_id');
// if (empty($client_id)) {
// return $this->respond(['status' => false, 'message' => 'Client id required'], 404);
// }
// // 1. Client Model
// $client_data = $this->clientModel->where('id', $client_id)->where('is_active', 1)->first();
// $this->myLogger->logme('error', "Client data : " . json_encode($client_data ?? []));
// if (!empty($client_data)) {
// $is_deleted = $this->clientModel->where('id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Client record does not exist.");
// }
// } else {
// return $this->respond(['status' => false, 'message' => 'Client not found'], 404);
// }
// // 2. Client RM Model
// $client_rm_data = $this->clientRMModel->where('client_id', $client_id)->first();
// $this->myLogger->logme('error', "Client Relationship Manager data : " . json_encode($client_rm_data ?? []));
// if (!empty($client_rm_data)) {
// $is_deleted = $this->clientRMModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client Relationship Manager data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Client Relationship Manager record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Client Relationship Manager data not found.");
// }
// // 3. Client KYC Docs Model
// $client_kyc_data = $this->clientKYCDocsModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Client KYC Docs data : " . json_encode($client_kyc_data ?? []));
// if (!empty($client_kyc_data)) {
// $is_deleted = $this->clientKYCDocsModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client KYC Docs data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Client KYC Docs record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Client KYC Docs data not found.");
// }
// // 4. Client Branch Model
// $client_branch_data = $this->clientBranchModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Client Branch data : " . json_encode($client_branch_data ?? []));
// $branch_ids = array_column($client_branch_data, 'id') ?? [];
// $this->myLogger->logme('error', "Client Branch id count : " . count($branch_ids ?? []));
// if (!empty($client_branch_data)) {
// $is_deleted = $this->clientBranchModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client Branch data removed successfully.");
// if(!empty($branch_ids)){
// $level_contact_data = $this->levelContactModel->where('contact_type', 'client')->whereIn('ref_id', $branch_ids)->findAll();
// $this->myLogger->logme('error', "Level Contact data : " . json_encode($level_contact_data ?? []));
// $is_deleted = $this->levelContactModel->where('contact_type', 'client')->whereIn('ref_id', $branch_ids)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Level Contact data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Level Contact record does not exist. To delete");
// }
// }else{
// $this->myLogger->logme('error', "Level Contact data not found.");
// }
// } else {
// $this->myLogger->logme('error', "Client Branch record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Client Branch data not found.");
// }
// // 5. Client Policy Model
// $client_policy_data = $this->clientPolicyModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Client Policy data : " . json_encode($client_policy_data ?? []));
// $policy_ids = array_column($client_policy_data, 'id') ?? [];
// $this->myLogger->logme('error', "Client Policy id count : " . count($policy_ids ?? []));
// if (!empty($client_policy_data)) {
// $is_deleted = $this->clientPolicyModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client Policy data removed successfully.");
// if(!empty($policy_ids)){
// $employee_policy_data = $this->employeePolicyModel->whereIn('client_policy_id', $policy_ids)->findAll();
// $this->myLogger->logme('error', "Employee Policy data count : " . count($employee_policy_data ?? []));
// $is_deleted = $this->employeePolicyModel->whereIn('client_policy_id', $policy_ids)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Employee policy data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Employee policy record does not exist. To delete");
// }
// }else{
// $this->myLogger->logme('error', "Employee policy data not found.");
// }
// } else {
// $this->myLogger->logme('error', "Client Policy record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Client Policy data not found.");
// }
// // 6. Employee Model
// $employee_data = $this->employeeModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Employee data count : " . count($employee_data ?? []));
// if (!empty($employee_data)) {
// $is_deleted = $this->employeeModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Employee data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Employee record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Employee data not found.");
// }
// // 7. Client Deposit Model
// $client_deposit_data = $this->clientDepositModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Client Deposit data : " . json_encode($client_deposit_data ?? []));
// if (!empty($client_deposit_data)) {
// $is_deleted = $this->clientDepositModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Client Deposit data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Client Deposit record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Client Deposit data not found.");
// }
// // 8. Policy Premium 1 Model
// $policy_premium1_data = $this->policyPremium1Model->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Policy Premium 1 data count : " . count($policy_premium1_data ?? []));
// if (!empty($policy_premium1_data)) {
// $is_deleted = $this->policyPremium1Model->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Policy Premium 1 data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Policy Premium 1 record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Policy Premium 1 data not found.");
// }
// // 9. Policy Premium 2 Model
// $policy_premium2_data = $this->policyPremium2Model->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Policy Premium 2 data count: " . count($policy_premium2_data ?? []));
// if (!empty($policy_premium2_data)) {
// $is_deleted = $this->policyPremium2Model->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Policy Premium 2 data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Policy Premium 2 record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Policy Premium 2 data not found.");
// }
// // 10. Notification Model
// $notification_data = $this->notificationModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Notification data : " . json_encode($notification_data ?? []));
// if (!empty($notification_data)) {
// $is_deleted = $this->notificationModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Notification data removed successfully.");
// } else {
// $this->myLogger->logme('error', "Notification record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Notification data not found.");
// }
// // 11. CD Master Model
// $cd_master_data = $this->CDMasterModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "CD Master data : " . json_encode($cd_master_data ?? []));
// if (!empty($cd_master_data)) {
// $is_deleted = $this->CDMasterModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "CD Master data removed successfully.");
// } else {
// $this->myLogger->logme('error', "CD Master record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "CD Master data not found.");
// }
// // 12. Policy Transaction Model
// $policy_transaction_data = $this->policyTransactionModel->where('client_id', $client_id)->findAll();
// $this->myLogger->logme('error', "Policy Transaction data : " . json_encode($policy_transaction_data ?? []));
// $pt_ids = array_column($policy_transaction_data, 'id') ?? [];
// $this->myLogger->logme('error', "Policy Transaction id count : " . count($pt_ids ?? []));
// if (!empty($policy_transaction_data)) {
// $is_deleted = $this->policyTransactionModel->where('client_id', $client_id)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "Policy Transaction data removed successfully.");
// if(!empty($pt_ids)){
// $pt_co_share_data = $this->PTCOShareDetailsModel->whereIn('pt_id', $pt_ids)->findAll();
// $this->myLogger->logme('error', "PT CO Share data : " . json_encode($pt_co_share_data ?? []));
// $is_deleted = $this->PTCOShareDetailsModel->whereIn('pt_id', $pt_ids)->delete();
// if ($is_deleted) {
// $this->myLogger->logme('error', "PT CO Share data removed successfully.");
// } else {
// $this->myLogger->logme('error', "PT CO Share record does not exist. To delete");
// }
// }else{
// $this->myLogger->logme('error', "PT CO Share data not found.");
// }
// } else {
// $this->myLogger->logme('error', "Policy Transaction record does not exist. To delete");
// }
// } else {
// $this->myLogger->logme('error', "Policy Transaction data not found.");
// }
// $this->myLogger->logme('error', "Wipe Demo Client function closed");
// return $this->respond(['status' => true, 'message' => 'Demo client data wiped successfully'], 200);
// }
public function wipeDemoClient()
{
$this->myLogger->logme('error', "========================================");

View File

@ -1862,6 +1862,7 @@ class EmpDataServiceController extends BaseController
$status = $file['status'];
$batch_code = $file['batch_code'];
$user_id = $file['created_by'];
$policy_issue_date = $file['policy_issue_date'];
$insurer_id = $this->clientPolicyModel->where('id', $client_policy_id)->first();
@ -2086,6 +2087,7 @@ class EmpDataServiceController extends BaseController
'no_of_dependent' => count($no_of_dependent ?? []) ?? null,
'base_premium' => $base_bremium_and_gst['base_premium'] ?? null,
'gst' => $base_bremium_and_gst['gst'] ?? null,
'policy_issue_date' => $policy_issue_date ?? null,
]]);
// $this->cashDepositCalculationForInception($depositeData);
@ -2417,6 +2419,7 @@ class EmpDataServiceController extends BaseController
$batch_code = $file['batch_code'];
$user_id = $file['created_by'];
$event_type = $file['event_type'];
$policy_issue_date = $file['policy_issue_date'];
$status_val = 'success';
@ -2519,6 +2522,7 @@ class EmpDataServiceController extends BaseController
'endorsement_no' => $endorsement_id[0] ?? null,
'emp_count' => $emp_count ?? null,
'action_type' => $file['event_type'] ?? null,
'policy_issue_date' => $policy_issue_date ?? null,
]]);
@ -2999,6 +3003,7 @@ class EmpDataServiceController extends BaseController
$status = $file['status'];
$batch_code = $file['batch_code'];
$user_id = $file['created_by'];
$policy_issue_date = $file['policy_issue_date'];
$insurer_id = $this->clientPolicyModel->where('id', $client_policy_id)->first();
@ -3179,6 +3184,7 @@ class EmpDataServiceController extends BaseController
'no_of_dependent' => count($no_of_dependent ?? []) ?? null,
'base_premium' => $base_bremium_and_gst['base_premium'] ?? null,
'gst' => $base_bremium_and_gst['gst'] ?? null,
'policy_issue_date' => $policy_issue_date ?? null,
]]);
}
@ -3537,6 +3543,7 @@ class EmpDataServiceController extends BaseController
$status = $file['status'];
$batch_code = $file['batch_code'];
$user_id = $file['created_by'];
$policy_issue_date = $file['policy_issue_date'];
$insurer_id = $this->clientPolicyModel->where('id', $client_policy_id)->first();
@ -3687,6 +3694,7 @@ class EmpDataServiceController extends BaseController
'no_of_dependent' => count($no_of_dependent ?? []) ?? null,
'base_premium' => $base_bremium_and_gst['base_premium'] ?? null,
'gst' => $base_bremium_and_gst['gst'] ?? null,
'policy_issue_date' => $policy_issue_date ?? null,
]]);
}
@ -4981,7 +4989,7 @@ class EmpDataServiceController extends BaseController
'policy_no' => $policy_data['policy_no'] ?? null,
'cd_ac_no' => $policy_data['cd_ac_no'] ?? null,
'cd_ac_pk' => $policy_data['cd_ac_pk'] ?? null,
'policy_issue_date' => $policy_data['policy_start_date'] ?? null,
'policy_issue_date' => $policy_data['policy_issue_date'] ?? null,
'policy_start_date' => $policy_data['policy_start_date'] ?? null,
'policy_end_date' => $policy_data['policy_end_date'] ?? null,
'data_received_date' => $policy_data['data_received_date'] ?? null,
@ -4992,7 +5000,7 @@ class EmpDataServiceController extends BaseController
'co_share' => $policy_data['co_share'] ?? 0,
'pre_payable_by' => $policy_data['pre_payable_by'] ?? 1,
'renewal_date' => $policy_data['policy_end_date'] ?? null,
'month' => date('Y-m-01', strtotime($policy_data['policy_start_date'])) ?? null,
'month' => date('Y-m-01', strtotime($policy_data['policy_issue_date'] ?? "")) ?? null,
'ct_type' => 1,
'is_cd_reduce_from_bds' => 0,
'client_type_id' => 0,

View File

@ -277,22 +277,28 @@ class EmployeeController extends AdminController
$file_id = $this->fileModel->insert(['file_name' => $filename, 'client_id' => $client_id, 'policy_id' => $policy_id, 'created_by' => $loggedInUserID, 'status' => $status, 'action' => $action, 'client_branch_id' => $branch_id,'uploaded_by' => 1, 'hr_file_id' => $hr_file_id]); //here field policy_id have client_policy_id and not policy id from policy master
$this->myLogger->logme("error", '{file_id} uploaded success', ['file_id' => $file_id]);
//start validation process
if($fileSize < 1) // if file size less than 1
{
$empServiceController = new EmployeeServiceController();
$result = $empServiceController->excelFileFormatValidation(['file_id' => $file_id]);
$this->myLogger->logme("error", '{file_id} is less than 1MB, validating on the fly', ['file_id' => $file_id]);
//endof validation process
if (isset($result['error_summary']) && count($result['error_summary'])) {
return $this->respond(['dataStatus' => false, 'code' => 404, 'message' => 'file rejected with errors'], 200);
}
}
else //if file size greater than 1 add the file as job
{
$job_details = new Jobs();
$r = Jobs::addJob(['job_name' => 'excelFileFormatValidation','payload' => ['file_id' => $file_id]]);
if ($action == "all") {
$r = Jobs::addJob(['job_name' => 'excelMultieventFileFormateValidation', 'payload' => ['file_id' => $file_id]]);
$this->myLogger->logme("error", '{file_id} is greather than 1MB, validating with job queue', ['file_id' => $file_id]);
} else {
//start validation process
if ($fileSize < 1) // if file size less than 1
{
$empServiceController = new EmployeeServiceController();
$result = $empServiceController->excelFileFormatValidation(['file_id' => $file_id]);
$this->myLogger->logme("error", '{file_id} is less than 1MB, validating on the fly', ['file_id' => $file_id]);
//endof validation process
if (isset($result['error_summary']) && count($result['error_summary'])) {
return $this->respond(['dataStatus' => false, 'code' => 404, 'message' => 'file rejected with errors'], 200);
}
} else //if file size greater than 1 add the file as job
{
$job_details = new Jobs();
$r = Jobs::addJob(['job_name' => 'excelFileFormatValidation', 'payload' => ['file_id' => $file_id]]);
$this->myLogger->logme("error", '{file_id} is greather than 1MB, validating with job queue', ['file_id' => $file_id]);
}
}
return $this->respond(['dataStatus' => true, 'code' => 200, 'data' => 'file upload success'], 200);
@ -303,7 +309,7 @@ class EmployeeController extends AdminController
//for TPA/insurer upload
$data['events'] = ['inception' => 'Inception (Employee + Dependents)', 'missed_inception' => 'Missed Inception (Employee + Dependents)', 'addition' => 'Addition (Employee + Dependents)', 'dependent_addition' => 'Dependent Addition (Only Dependents)', 'deletion' => 'Deletion', 'correction' => 'Correction', 'si_enhancement' => 'SI Enhancement'];
//for inception upload
$data['actions'] = ['inception' => 'Inception (Employee + Dependents)', 'missed_inception' => 'Missed Inception (Employee + Dependents)', 'addition' => 'Addition (Employee + Dependents)', 'dependent_addition' => 'Dependent Addition (Only Dependents)', 'deletion' => 'Deletion', 'correction' => 'Correction', 'si_enhancement' => 'SI Enhancement'];
$data['actions'] = ['all' => 'All', 'inception' => 'Inception (Employee + Dependents)', 'missed_inception' => 'Missed Inception (Employee + Dependents)', 'addition' => 'Addition (Employee + Dependents)', 'dependent_addition' => 'Dependent Addition (Only Dependents)', 'deletion' => 'Deletion', 'correction' => 'Correction', 'si_enhancement' => 'SI Enhancement'];
// $data['actions'] = ['inception' => 'Inception (Employee + Dependents)', 'missed_inception' => 'Missed Inception (Employee + Dependents)', 'addition' => 'Addition (Employee + Dependents)', 'dependent_addition' => 'Dependent Addition (Only Dependents)', 'deletion' => 'Deletion', 'correction' => 'Correction', 'si_enhancement' => 'SI Enhancement','enrollment' => 'Enrolment'];
// $data['import_or_export'] = ['import' => 'Import', 'export' => 'Export'];
@ -469,6 +475,8 @@ class EmployeeController extends AdminController
$filePath = ROOTPATH . 'public/sample_excel/sample_inception.xls';
}else if ($actionType == 'member_data') {
$filePath = ROOTPATH . 'public/sample_excel/Sample_Member_Data.xlsx';
}else if ($actionType == 'all') {
$filePath = ROOTPATH . 'public/sample_excel/sample_multievent_file.xlsx';
}
// Check if the file exists
@ -515,6 +523,7 @@ class EmployeeController extends AdminController
$client_branch_id = $this->request->getPost('client_branch_id');
$insurer_or_tpa = $this->request->getPost('insurer_or_tpa');
$actions = $this->request->getPost('action_type');
$policy_issue_date = $this->request->getPost('policy_issue_date');
$client_data = $this->clientPolicyModel->getCliendDataForExcelFileName($client_policy_id);
$file_name = generate_filename($client_data['short_name'], $event_type, $actions, $insurer_or_tpa, $client_data['policy_type'], $client_data['branch_code']);
@ -530,6 +539,13 @@ class EmployeeController extends AdminController
'actions' => $actions,
'file_name' => $file_name,
];
$batch_data['policy_issue_date'] = (!empty($policy_issue_date) && strtotime($policy_issue_date) !== false)
? change_date_format($policy_issue_date)
: null;
if ($actions == 'export') {
if ($event_type == 'inception' || $event_type == 'addition' || $event_type == 'dependent_addition' || $event_type == 'missed_inception' || ($event_type == 'MultipleEvents' && $insurer_or_tpa == 'tpa')) {

File diff suppressed because it is too large Load Diff

View File

@ -307,7 +307,7 @@ public function convertToPdf($inputFile = null)
{
// Customize this based on your needs
$html = '<h2>' . htmlspecialchars($worksheet->getTitle()) . '</h2>';
$html .= '<table border="1" cellpadding="5">';
$html .= '<table data-custom-table-css="table" border="1" cellpadding="5">';
foreach ($worksheet->getRowIterator() as $row) {
$html .= '<tr>';

View File

@ -155,6 +155,18 @@ class JobWorker extends AdminController
'type' => 'CC', // Handler Category
'handler' => 'App\Controllers\TicketServiceController',
],
'excelMultieventFileFormateValidation' => [
'type' => 'CC', // Handler Category
'handler' => 'App\Controllers\EmployeeMultiEventServiceController',
],
'excelMultieventFileDataValidation' => [
'type' => 'CC', // Handler Category
'handler' => 'App\Controllers\EmployeeMultiEventServiceController',
],
'excelMultieventFileOnBoard' => [
'type' => 'CC', // Handler Category
'handler' => 'App\Controllers\EmployeeMultiEventServiceController',
],
];

View File

@ -31,6 +31,7 @@ use App\Models\InsurerModel;
use App\Models\OccupancyMasterModel;
use App\Models\LeadFilesModel;
use App\Models\LeadInstallmentPaymentDetails;
use App\Models\GmailSentHistoryModel;
use App\Helpers\MailHelper;
use App\Helpers\ExcelMergeHelper;
@ -70,6 +71,7 @@ class LeadsController extends BaseController
protected $occupancyModel;
protected $leadFilesModel;
protected $leadInstallmentPaymentDetails;
protected $gmailSentHistoryModel;
//variables for storing array
protected $issuer;
@ -102,6 +104,7 @@ class LeadsController extends BaseController
$this->occupancyModel = new OccupancyMasterModel();
$this->leadFilesModel = new LeadFilesModel();
$this->leadInstallmentPaymentDetails = new LeadInstallmentPaymentDetails();
$this->gmailSentHistoryModel = new GmailSentHistoryModel();
$this->issuer = [1 => 'JIBS', 2 => 'Nhance'];
$this->clientType = [1 => 'Group', 2 => 'Individual'];
@ -383,6 +386,20 @@ class LeadsController extends BaseController
$data['source_policy_end_date'] = null;
}
//convert the date
if (!empty($data['next_reminder_date'])) {
$data['next_reminder_date'] = change_date_format($data['next_reminder_date']);
} else {
$data['next_reminder_date'] = null;
}
//convert 0 and 1
if (isset($data['is_insurer_auto_mail'])) {
$data['is_insurer_auto_mail'] = 1;
} else {
$data['is_insurer_auto_mail'] = 0;
}
// $file_name = file_Upload($files[$index], $uploadFilePath);
$last_3_years_claims = $data['finyear'];
@ -459,9 +476,12 @@ class LeadsController extends BaseController
'lead_form_type' => $data['lead_form_type'] ?? 1,
'custom_fields' => $data['custom_fields'] ?? null,
'source_policy_start_date' => $data['source_policy_start_date'] ?? null,
'source_policy_end_date' => $data['source_policy_end_date'] ?? null,
'claim_history' => $data['claim_history'] ?? 0
'source_policy_start_date' => $data['source_policy_start_date'] ?? null,
'source_policy_end_date' => $data['source_policy_end_date'] ?? null,
'claim_history' => $data['claim_history'] ?? 0,
'next_reminder_date' => $data['next_reminder_date'] ?? 0,
'is_insurer_auto_mail' => $data['is_insurer_auto_mail'] ?? 0
];
}
// print_r($processedData);die();
@ -856,21 +876,40 @@ class LeadsController extends BaseController
$qcr_created = true;
}
if (($data['submit_type'] ?? "") == 'QCR') {
$quote_received_insurer = [];
if (($data['submit_type'] ?? "") === 'QCR') {
$inputJson = json_decode($data['json'], true);
$proposal_data = array_pop($inputJson);
if (isset($proposal_data['proposal_data']['over_all_column_data'])) {
$proposel_count = $proposal_data['proposal_data']['over_all_column_data'];
$proposal_data = $inputJson['proposal_data'] ?? array_pop($inputJson);
if (isset($proposal_data['over_all_column_data'])) {
$proposel_count = $proposal_data['over_all_column_data'];
$this->myLogger->logme("error", "insurer id : " . json_encode($proposel_count));
foreach ($proposel_count as $key => $value) {
if (!empty($value['insurers'])) {
$qcr_created = true;
foreach ($value['insurers'] as $insurer => $id) {
if (!empty($id['id'])) {
$quote_received_insurer[] = $id['id'];
}
}
}
}
}
}
$this->myLogger->logme("error", "quote_received_insurer : " . json_encode($quote_received_insurer));
$data['type'] = 1;
//update the quote received insurer data to the lead
if(count($quote_received_insurer) != 0){
$this->leadsModel->update($lead_id, ['quote_received_insurer' => json_encode($quote_received_insurer ?? [])]);
$this->myLogger->logme("error", "quote_received_insurer data updated in the lead: " . json_encode($quote_received_insurer));
}
// Deactivate existing RFQs for this lead and type
if (!isset($data['rfq_primaryKey']) && empty($data['rfq_primaryKey'])) {
$this->RFQModel
@ -2552,6 +2591,21 @@ class LeadsController extends BaseController
$from_mail = "bs@nhanceindia.in";
}
$type = "";
$insurer_ids = null;
if (in_array($recipient_type, ['placement'])) {
$type = "placement";
} else if (in_array($recipient_type, ['insurer'])) {
$type = "insurer";
$insurer_ids = json_decode($params['insurer_ids'] ?? "", true) ?? [];
}else if (in_array($recipient_type, ['internal'])) {
$type = "internal";
}else if (in_array($recipient_type, ['client'])) {
$type = "client";
}
// print_r($insurer_ids); die;
if ($recipient_type === 'placement') {
$lead_data = $this->leadsModel->find($lead_id);
@ -2733,7 +2787,7 @@ class LeadsController extends BaseController
$subject = $file_type == 'rfq' ? 'Request for Quotation from ' . $lead_data['client_name'] . ' for ' . $lead_data['policy_type'] : 'Quotation Comparison Report for ' . $lead_data['policy_type'];
$original_message = '<div style="width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9;font-family:Arial,sans-serif;color:#333;line-height:1.6"><div style=background-color:#4a90e2;color:#fff;padding:15px;text-align:center><h1 style=margin:0;font-size:24px>Request for Quotation (RFQ)</h1></div><div style=padding:20px;background-color:#fff><h2 style=color:#4a90e2;font-size:20px;margin-top:0>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2 style=color:#4a90e2;font-size:20px;margin-top:20px>RFQ Details</h2><table style=width:100%;border-collapse:collapse;margin-top:20px><tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Client name<td style="border:1px solid #ddd;padding:10px;text-align:left">{{CLIENT_NAME}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Coverage Type<td style="border:1px solid #ddd;padding:10px;text-align:left">{{POLICY_LONG_NAME}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Policy Start Date<td style="border:1px solid #ddd;padding:10px;text-align:left">{{POLICY_START_DATE}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Policy Duration<td style="border:1px solid #ddd;padding:10px;text-align:left">{{DURATION}}</table><div style="margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic">Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div style=margin-top:20px;font-size:12px;color:#777;text-align:center><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$original_message = '<div style="width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9;font-family:Arial,sans-serif;color:#333;line-height:1.6"><div style=background-color:#4a90e2;color:#fff;padding:15px;text-align:center><h1 style=margin:0;font-size:24px>Request for Quotation (RFQ)</h1></div><div style=padding:20px;background-color:#fff><h2 style=color:#4a90e2;font-size:20px;margin-top:0>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2 style=color:#4a90e2;font-size:20px;margin-top:20px>RFQ Details</h2><table data-custom-table-css="table" style=width:100%;border-collapse:collapse;margin-top:20px><tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Client name<td style="border:1px solid #ddd;padding:10px;text-align:left">{{CLIENT_NAME}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Coverage Type<td style="border:1px solid #ddd;padding:10px;text-align:left">{{POLICY_LONG_NAME}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Policy Start Date<td style="border:1px solid #ddd;padding:10px;text-align:left">{{POLICY_START_DATE}}<tr><th style="border:1px solid #ddd;padding:10px;text-align:left;background-color:#f2f2f2">Policy Duration<td style="border:1px solid #ddd;padding:10px;text-align:left">{{DURATION}}</table><div style="margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic">Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div style=margin-top:20px;font-size:12px;color:#777;text-align:center><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
//for mail content
if (!empty($mail_content)) {
@ -2746,10 +2800,14 @@ class LeadsController extends BaseController
}
// print_r($subject); die;
$common = ['module' => "leads", 'pk' => $lead_id, 'mail_type' => $type, 'common' => null];
if ($recipient_data) {
foreach ($recipient_data as $recipient) {
foreach ($recipient_data as $position => $recipient) {
if ($recipient_type == 'insurer'){
$common['common'] = $insurer_ids[$position] ?? null;
}
$message = $original_message;
$message = str_replace("{{RECIPIENT_NAME}}", $recipient['name'] != "" ? $recipient['name'] : " ", $message);
$message = str_replace("{{CLIENT_NAME}}", $lead_data['client_name'] != "" ? $lead_data['client_name'] : "", $message);
@ -2761,7 +2819,7 @@ class LeadsController extends BaseController
$string = implode(", ", $cc_mails);
$bcc_string = implode(", ", $bcc_mails);
$res = MailHelper::send_email(['from_mail' => $from_mail, 'mail' => $recipient['email'], 'cc' => $string, 'subject' => $subject, 'message' => $message, 'attachments' => $attachments, 'reply_to' => $reply_to, 'bcc' => $bcc_string]);
$res = MailHelper::send_email(['from_mail' => $from_mail, 'mail' => $recipient['email'], 'cc' => $string, 'subject' => $subject, 'message' => $message, 'attachments' => $attachments, 'reply_to' => $reply_to, 'bcc' => $bcc_string, 'common' => $common]);
// !dd($res);
$result_data[] = ['mail' => $recipient['email'], 'status' => $res];
}
@ -3539,10 +3597,11 @@ class LeadsController extends BaseController
$message = str_replace("{{POLICY_YEAR}}", $policy_year, $message);
$message = str_replace("{{POLICY_END_DATE}}", " (Due On " . $formatted_policy . ")", $message);
$message = str_replace("{{LOGGED_USER_NAME}}", ucfirst($logged_user_data['first_name']) . " " . ucfirst($logged_user_data['last_name']), $message);
$message = str_replace("{{LOGGED_USER_EMAIL}}", $logged_user_data['email'], $message);
$message = str_replace("{{LOGGED_USER_MOBILE}}", $logged_user_data['mobile'], $message);
$message = str_replace("{{LOGO_PATH}}", $log_path, $message);
$message = str_replace("{{LOGGED_USER_NAME}}", ucfirst($logged_user_data['first_name'] ?? "") . " " . ucfirst($logged_user_data['last_name'] ?? ""), $message);
$message = str_replace("{{LOGGED_USER_EMAIL}}", $logged_user_data['email'] ?? "", $message);
$message = str_replace("{{LOGGED_USER_MOBILE}}", $logged_user_data['mobile'] ?? "", $message);
$message = str_replace("{{LOGO_PATH}}", $log_path ?? "", $message);
return $message;
} else {
@ -3627,7 +3686,7 @@ class LeadsController extends BaseController
}
if (!empty($data['lead_edit_data'])) {
foreach (['policy_start_date', 'policy_end_date', 'source_policy_start_date', 'source_policy_end_date', 'incurred_claims_date'] as $dateField) {
foreach (['policy_start_date', 'policy_end_date', 'source_policy_start_date', 'source_policy_end_date', 'incurred_claims_date', 'next_reminder_date'] as $dateField) {
$data['lead_edit_data'][$dateField] = !empty($data['lead_edit_data'][$dateField])
? change_date_format($data['lead_edit_data'][$dateField], 'Y-m-d', 'd/m/Y')
: null;
@ -3657,6 +3716,28 @@ class LeadsController extends BaseController
return $this->loadLayout('leads_form_handler', $data);
}
public function getLeadEmailHistory($id){
if(!empty($id)){
$result = $this->gmailSentHistoryModel
->where('pk', $id)
->where('module',"leads")
->orderBy('created_at', 'desc')
->findAll();
if(!empty($result)){
$result = !empty($result) ? $result : [];
return $this->response->setJSON((['status' => 'success', 'data' => $result]))->setStatusCode(200);
}else{
return $this->response->setJSON((['status' => 'error', 'message' => 'No History found']))->setStatusCode(400);
}
}else{
return $this->response->setJSON((['status' => 'error', 'message' => 'ID not found']))->setStatusCode(404);
}
// Select * from gmail_sent_history where pk != "" and module = "leads";
// echo $id;
}
public function getPolicyTypeFields()
{
@ -4866,7 +4947,7 @@ class LeadsController extends BaseController
// Start table with clean styling
$html .= "<h3 style='color: #333; font-weight: 500; margin-bottom: 15px;'>{$category}</h3>";
$html .= "<table style='width: 100%; border-collapse: collapse; font-family: Arial, sans-serif; font-size: 14px;'>";
$html .= "<table data-custom-table-css='table' style='width: 100%; border-collapse: collapse; font-family: Arial, sans-serif; font-size: 14px;'>";
// Table header with light background
$html .= "<tr>";
@ -4893,4 +4974,197 @@ class LeadsController extends BaseController
return $html;
}
// function for insurer remainder mail cron job
public function remainderForQcr()
{
$lead_data = $this->leadsModel
->select(
'leads.*,
user_profiles.email as created_person_email,
policy_type.policy_type,
policy_type.long_name
')
->join('policy_type', 'leads.policy_type_id = policy_type.id')
->join('user_profiles', 'leads.created_by = user_profiles.id', 'left')
->where('leads.is_active', 1)
->where('user_profiles.is_active', 1)
->whereIn('leads.status', ['rfq_sent', 'qcr_created'])
->where('leads.next_reminder_date', date('Y-m-d'))
->findAll();
// dd($lead_data);
if (count($lead_data) == 0) {
$this->myLogger->logme("info", "No leads found for reminder mail at " . date('Y-m-d H:i:s'));
print_r(["status" => true, "message" => "There is no data to send reminder mail"]);
return ["status" => true, "message" => "There is no data to send reminder mail"];
}
$from_mail = "im@nhanceindia.in";
$subject = "Reminder for RFQ";
$content_string = '
<p>Dear Sir,</p>
<p>Greetings from Nhance India!</p>
<p>This is a gentle reminder regarding our earlier mail about the RFQ for the <strong>{{POLICY_TYPE}}</strong> policy pertaining to <strong>{{CLIENT_NAME}}</strong>.</p>
<p>We kindly request you to share the competitive quotes at the earliest possible convenience.</p>
<p>In case of any clarification, please feel free to contact us.</p>
<p>Thank you for your prompt attention to this matter.</p><br>
<p>Best regards,</p>
<p><strong>Nhance India</strong></p>
';
$reminder_sended_lead = [];
foreach ($lead_data as $lead) {
$leadId = $lead['id'];
$reply_to = $lead['created_person_email'] ?? "";
if (isset($lead['policy_end_date']) && $lead['policy_end_date'] != null) {
$subject = "{{CLIENT_NAME}} _ {{POLICY_TYPE}} _ {{RFQ_OR_QCR}} _ {{POLICY_YEAR}} {{POLICY_END_DATE}}";
} else {
$subject = "{{CLIENT_NAME}} _ {{POLICY_TYPE}} _ {{RFQ_OR_QCR}} _ {{POLICY_YEAR}}";
}
$mail_content = $this->transformMailContent($lead, $content_string, "RFQ");
$mail_subject = $this->transformMailContent($lead, $subject, "RFQ");
$this->myLogger->logme("info", "Processing lead_id={$leadId} for reminder mails");
// get sales person + created_by emails
$sales_person_emails = $this->userModel
->select('email')
->where('is_active', 1)
->whereIn('id', json_decode($lead['salse_person_id'] ?? "[]", true))
->findAll();
$email_list = array_column($sales_person_emails, 'email');
if (!empty($reply_to)) {
$email_list[] = $reply_to;
}
$email_list = array_filter(array_unique($email_list));
$email_string = implode(',', $email_list);
// Get latest sent mail timestamp
$createdAtRow = $this->gmailSentHistoryModel
->select("DATE_FORMAT(created_at, '%Y-%m-%d %H:%i') as created_at", false)
->where('isactive', 1)
->where('mail_type', 'insurer')
->where('pk', $leadId)
->orderBy('id', 'desc')
->first();
// dd(db_connect()->getLastQuery(), $createdAtRow);
if (!$createdAtRow) {
$this->myLogger->logme("warning", "No sent history found for lead_id={$leadId}, skipping...");
continue;
}
$createdAt = $createdAtRow['created_at'];
// Fetch mail data for that timestamp
$mail_datas = $this->gmailSentHistoryModel
->where('isactive', 1)
->where('mail_type', "insurer")
->where('pk', $leadId)
->where("DATE_FORMAT(created_at, '%Y-%m-%d %H:%i')", $createdAt)
->findAll();
if (empty($mail_datas)) {
$this->myLogger->logme("warning", "No mail data found for lead_id={$leadId} at created_at={$createdAt}");
continue;
}
// Filter only pending insurers
$quote_received_insurer = json_decode($lead['quote_received_insurer'] ?? "[]", true);
$reminder_mail_data = [];
if (empty($quote_received_insurer)) {
$reminder_mail_data = $mail_datas;
} else {
foreach ($mail_datas as $mail_value) {
$insurer_id = $mail_value['common'] ?? "";
if (!in_array($insurer_id, $quote_received_insurer)) {
$reminder_mail_data[] = $mail_value;
}
}
}
// dd($reminder_mail_data);
if (empty($reminder_mail_data)) {
$this->myLogger->logme("info", "All insurers already responded for lead_id={$leadId}, no reminder needed");
continue;
}
$this->myLogger->logme("info", "Sending " . count($reminder_mail_data) . " reminder mail(s) for lead_id={$leadId}");
$common = ['module' => "leads", 'pk' => $leadId, 'mail_type' => "remainder", 'common' => null];
foreach ($reminder_mail_data as $content) {
$insurerId = $content['common'] ?? null;
$common['common'] = $insurerId;
try {
if ($lead['is_insurer_auto_mail'] == 1) {
// send reminder to insurer
$res = MailHelper::send_email([
'from_mail' => $from_mail,
'mail' => $content['mail'] ?? "",
'cc' => json_decode($content['cc'] ?? "", true) ?? "",
'subject' => $mail_subject ?? "",
'message' => $mail_content ?? "",
'reply_to' => $reply_to,
'bcc' => json_decode($content["bcc"] ?? "", true) ?? "",
'common' => $common
]);
$this->myLogger->logme("info", "Reminder mail sent to the insurer | lead_id={$leadId}, insurer_id={$insurerId}, response=" . json_encode($res));
$reminder_sended_lead[] = [
'lead_id' => $leadId,
'insurer_id' => $insurerId,
'response' => $res
];
} else{
$this->myLogger->logme("info", "Reminder mail disable for this lead_id={$leadId}");
}
} catch (\Throwable $e) {
$errorDetails = [
'error_message' => $e->getMessage(),
'file' => $e->getFile(),
'line' => $e->getLine(),
'stack_trace' => $e->getTraceAsString(),
];
$this->myLogger->logme("error", "Exception while sending reminder | lead_id={$leadId}, insurer_id={$insurerId}, error=" . json_encode($errorDetails));
$reminder_sended_lead[] = [
'lead_id' => $leadId,
'insurer_id' => $insurerId,
'response' => ['status' => false, 'error' => $errorDetails]
];
}
// send reminder to sales person / creator only
$internal_mail_response = MailHelper::send_email([
'mail' => $from_mail,
'cc' => $email_string,
'subject' => $mail_subject ?? "",
'message' => $mail_content ?? "",
'common' => $common
]);
$this->myLogger->logme("info", "Reminder mail sent to sales persons | lead_id={$leadId}, recipients={$email_string}, response=" . json_encode($internal_mail_response));
}
}
return ['status' => true, "data" => $reminder_sended_lead];
}
}

View File

@ -1798,7 +1798,7 @@ class MasterController extends AdminController
$email_id = CLI::getOption('to') ? CLI::getOption('to') : $email_id;
// print_r($email_id);die();
// $gmailapi = \Config\Services::gmailapi();
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table data-custom-table-css="table" class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
// $attachments = [
// ["filePath" => WRITEPATH."uploads/excel/sample/correction.xls","fileName" => "correction.xls"],
@ -1821,7 +1821,7 @@ class MasterController extends AdminController
public function testZeptoSMTP()
{
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table data-custom-table-css="table" class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$attachments = [
["filePath" => ROOTPATH . "public/sample_excel/sample_addition.xls", "fileName" => "sample_addition.xls"],
["filePath" => ROOTPATH . "public/sample_excel/sample_inception.xls", "fileName" => "sample_inception.xls"],
@ -1973,7 +1973,7 @@ class MasterController extends AdminController
public function sendMutipleToEmails()
{
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$message = '<style>body{font-family:Arial,sans-serif;color:#333;line-height:1.6;margin:0;padding:0}.email-container{width:100%;max-width:600px;margin:0 auto;padding:20px;border:1px solid #e0e0e0;background-color:#f9f9f9}.header{background-color:#4a90e2;color:#fff;padding:15px;text-align:center}.header h1{margin:0;font-size:24px}.content{padding:20px;background-color:#fff}.content h2{color:#4a90e2;font-size:20px;margin-top:0}.content p{margin:10px 0}.details-table{width:100%;border-collapse:collapse;margin-top:20px}.details-table td,.details-table th{border:1px solid #ddd;padding:10px;text-align:left}.details-table th{background-color:#f2f2f2}.footer{margin-top:20px;font-size:12px;color:#777;text-align:center}.attachment-note{margin-top:20px;padding:10px;background-color:#f7f7f7;border-left:4px solid #4a90e2;font-style:italic}</style><div class=email-container><div class=header><h1>Request for Quotation (RFQ)</h1></div><div class=content><h2>Dear {{RECIPIENT_NAME}},</h2><p>We are reaching out to request a quotation for the following insurance coverage. Please review the details below and provide your quote at your earliest convenience.<h2>RFQ Details</h2><table data-custom-table-css="table" class=details-table><tr><th>Client name<td>{{CLIENT_NAME}}<tr><th>Coverage Type<td>{{POLICY_LONG_NAME}}<tr><th>Policy Start Date<td>{{POLICY_START_DATE}}<tr><th>Policy Duration<td>{{DURATION}}</table><div class=attachment-note>Please note: Additional terms and details are included in the attachment for your reference.</div><p>Please feel free to reach out if you require any further information to prepare the quote. We look forward to receiving your proposal.<p>Best regards,<p><strong>Nhance India Pvt Ltd</strong><br></div><div class=footer><p>© Nhance India Pvt Ltd. All rights reserved.</div></div>';
$attachments = [
["filePath" => ROOTPATH . "public/sample_excel/sample_addition.xls", "fileName" => "sample_addition.xls"],
["filePath" => ROOTPATH . "public/sample_excel/sample_inception.xls", "fileName" => "sample_inception.xls"],

View File

@ -0,0 +1,25 @@
<?php
namespace App\Controllers;
use App\Controllers\BaseController;
use CodeIgniter\HTTP\ResponseInterface;
use CodeIgniter\API\ResponseTrait;
class TestingController extends BaseController
{
use ResponseTrait;
public function saveForm()
{
// Get JSON input
$data = $this->request->getPost();
// For testing: just return the received data
return $this->respond([
'status' => 'success',
'message' => 'Form data received successfully!',
'data' => $data
]);
}
}

View File

@ -8,12 +8,13 @@ use CodeIgniter\HTTP\ResponseInterface;
use App\Models\ThzMasterModel;
use App\Models\ThzMasterNotesModel;
use App\Models\ThzTypeModel;
use App\Models\ThzHistoryModel;
use App\ControllerCleaners\ThzControllerCleaner;
use App\Models\UserModel;
use App\Models\ClientPolicyModel;
use App\Models\ClientModel;
use App\Models\TicketMailTemplateModel;
// use App\Models\TicketTypesModel;
class ThzController extends BaseController
@ -21,7 +22,8 @@ class ThzController extends BaseController
protected $thzMasterModel;
protected $thzMasterNotesModel;
protected $thzTypeModel;
protected $thzHistoryModel;
protected $thzControllerCleaner;
protected $userModel;
@ -29,17 +31,20 @@ class ThzController extends BaseController
protected $clientModel;
protected $ticketMailTemplateModel;
// protected $ticketTypesModel;
protected $myLogger;
public function __construct()
{
$this->thzMasterModel = new ThzMasterModel();
$this->thzMasterNotesModel = new ThzMasterNotesModel();
$this->thzTypeModel = new thzTypeModel();
$this->thzHistoryModel = new ThzHistoryModel();
$this->thzControllerCleaner = new ThzControllerCleaner();
$this->userModel = new UserModel();
$this->clientPolicyModel = new ClientPolicyModel();
$this->clientModel = new ClientModel();
$this->clientModel = new ClientModel();
$this->ticketMailTemplateModel = new TicketMailTemplateModel();
$this->myLogger = \Config\Services::mylogger();
}
public function index()
@ -48,13 +53,36 @@ class ThzController extends BaseController
}
public function ticketSave(){
try
{
$data = $this->request->getPost();
if (!empty($data['thz_id'])) {
$text = "update";
$result = $this->updateTicket($data);
// here insert history Status.
$old = $this->thzMasterModel->where('thz_id', $data['thz_id'])->get()->getRowArray();
if ($old && isset($data['status'])) {
if ($old['status'] != $data['status']) {
$history = [
'thz_id' => $data['thz_id'],
'field_name' => 'status',
'display_name' => 'Status',
'old_value' => $old['status'],
'new_value' => $data['status'],
'is_active' => 1
];
if (!empty(get_session_userid())) {
$history['created_by'] = get_session_userid();
}
$this->thzHistoryModel->insert($history);
}
}
$updateID = $data['thz_id'];
} else {
@ -74,11 +102,27 @@ class ThzController extends BaseController
'message' => $result ? "Ticket {$text}d successfully " : "Unable to {$text} ticket. Please try again." ,
'notification' => $emailNotificationResult ? 'Email Notification Success..!!' : 'Email Notification Failed..!!'
])->setStatusCode($result ? 200 : 400);
} catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
public function ticketList()
{
try{
$returnType = strtolower($this->request->getGet('return_type') ?? 'api');
@ -92,7 +136,8 @@ class ThzController extends BaseController
if ($returnType === 'api') {
if (empty($tickets)) {
return $this->response->setJSON([ 'status' => 'error','message' => 'No tickets found'])->setStatusCode(404);
// return $this->response->setJSON([ 'status' => 'error','message' => 'No tickets found'])->setStatusCode(404);
throw new \RuntimeException('No tickets found', 400);
}
}else{
@ -101,18 +146,37 @@ class ThzController extends BaseController
$data['assignee'] = $this->userModel->where('is_active', 1)->whereIn('role', ['2', '3','4'])->findAll(); // enga 5-"head" and 1-"admin" assign pannvaga so dropdown la varakudhathu
// 2,3,4 remain person varannum.
$data['client_list'] = $this->clientModel->getCreatedByUserName();
$data['ticket_type'] = $this->thzTypeModel->where('is_active', 1)->findAll();
return $this->loadLayout('thz_list', $data);
}
return $this->response->setJSON([
'status' => 'success',
'data' => $tickets,
])->setStatusCode(200);
}
catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
public function ticketConversationSave(){
try {
$data = $this->request->getPost();
$data['notes_type'] = $data['notes_type'] ?? 'External' ;
@ -120,7 +184,8 @@ class ThzController extends BaseController
$result = $this->thzMasterNotesModel->insert($data);
if(empty($result)){
return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(404);
// return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(404);
throw new \RuntimeException('No tickets found', 404);
}
if($data['notes_type'] == "External"){
@ -136,41 +201,72 @@ class ThzController extends BaseController
'message' => $result ? "Ticket Notes created successfully" : "Unable to create ticket notes. Please try again." ,
'notification' => $emailNotificationResult ? 'Email Notification Success..!!' : 'Email Notification Failed Or No Need..!!'
])->setStatusCode($result ? 200 : 400);
}
catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
public function ticketAutoFetchDetails(){
public function ticketAutoFetchDetails()
{
try {
$data = $this->request->getPost();
$client_id = $data['client_id'];
$mobile = $data['mobile'];
$client_id = $data['client_id'] ?? null;
$mobile = $data['mobile'] ?? null;
if($client_id && $mobile){
$details = $this->thzMasterModel->ticketAutoFetchDetails($client_id ,$mobile);
if(empty($details)){
return $this->response->setJSON((['status' => 'error', 'message' => 'No Data found']))->setStatusCode(400);
}else{
$policyIds = array_column($details, 'policy_id');
$policyIds = array_filter($policyIds);
$clientPolicy = $this->clientPolicyModel->whereIn('id', $policyIds)->where('is_active', 1)->get()->getResultArray();
$result['client_details'] = $details;
$result['policy_details'] = empty($clientPolicy) ? [] : $clientPolicy ;
if ($client_id && $mobile) {
$details = $this->thzMasterModel->ticketAutoFetchDetails($client_id, $mobile);
if (empty($details)) {
throw new \RuntimeException('No Data found', 400);
}
}else{
return $this->response->setJSON((['status' => 'error', 'message' => 'Client and Mobile Not found']))->setStatusCode(400);
}
return $this->response->setJSON((['status' => 'success', 'data' => $result]))->setStatusCode(200);
$policyIds = array_filter(array_column($details, 'policy_id'));
$clientPolicy = !empty($policyIds)
? $this->clientPolicyModel->whereIn('id', $policyIds)->where('is_active', 1)->get()->getResultArray()
: [];
$result['client_details'] = $details;
$result['policy_details'] = $clientPolicy ?? [];
} else {
throw new \RuntimeException('Client and Mobile Not found', 400);
}
return $this->response->setJSON(['status' => 'success', 'data' => $result])->setStatusCode(200);
}
catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
public function ticketConversationList(){
public function ticketConversationList()
{
$data = $this->request->getGet();
$returnType = strtolower($this->request->getGet('return_type') ?? 'api');
@ -190,16 +286,32 @@ class ThzController extends BaseController
$notes = $this->thzMasterNotesModel->ticketConversationList($thz_id, $returnType );
$result['notes'] = !empty($notes) ? $notes : [];
}else{
return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(400);
// return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(400);
throw new \RuntimeException('No tickets found', 400);
}
}else{
return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(404);
// return $this->response->setJSON((['status' => 'error', 'message' => 'No tickets found']))->setStatusCode(404);
throw new \RuntimeException('No tickets found', 404);
}
if ($returnType === 'api') {
return $this->response->setJSON((['status' => 'success', 'data' => $result]))->setStatusCode(200);
try {
return $this->response->setJSON((['status' => 'success', 'data' => $result]))->setStatusCode(200);
} catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}else{
$assign_to = $result['master'][0]['assign_to'];
@ -222,49 +334,104 @@ class ThzController extends BaseController
$result['assignee'] = $this->userModel->where('is_active', 1)->whereIn('role', ['2', '3','4'])->findAll(); // enga 5-"head" and 1-"admin" assign pannvaga so dropdown la varakudhathu
// 2,3,4 remain person varannum.
$result['policy_terms'] = $toGetPolicyId ? $this->getPolicyTerms($toGetPolicyId) : '';
$result['ticket_type'] = $this->thzTypeModel->where('is_active', 1)->findAll();
return $this->loadLayout('thz_notes', $result);
}
}
}
// public function ticketType()
// {
// $method = $this->request->getMethod(); // get, post
// if ($method === 'get') {
// $types = $this->ticketTypesModel->where('is_active', 1)->findAll();
// if (empty($types)) {
// return $this->response->setJSON(['status' => 'error','message' => 'No ticket types found'])->setStatusCode(404);
// }
// return $this->response->setJSON(['status' => 'success','data' => $types])->setStatusCode(200);
// }
public function ticketType()
{
$method = $this->request->getMethod(); // get, post
try{
if ($method === 'get') {
$types = $this->thzTypeModel->select('id,name,is_active')->where('is_active', 1)->findAll();
if (empty($types)) {
return $this->response->setJSON(['status' => 'error','message' => 'No ticket types found'])->setStatusCode(404);
}
return $this->response->setJSON(['status' => 'success','data' => $types])->setStatusCode(200);
}
// if ($method === 'post') {
if ($method === 'post') {
// $data = $this->request->getPost();
// if (!empty($data['id'])) {
// $text = "update";
// $result = $this->ticketTypesModel->update($data['id'], $data);
// $updateID = $data['id'];
// } else {
// $text = "create";
// $insertID = $this->ticketTypesModel->insert($data);
// $result = true;
// }
$data = $this->request->getPost();
if (!empty($data['id'])) {
$text = "update";
$result = $this->thzTypeModel->update($data['id'], $data);
$updateID = $data['id'];
} else {
$text = "create";
$insertID = $this->thzTypeModel->insert($data);
$result = true;
}
// $id = isset($insertID) && !empty($insertID) ? $insertID : $updateID ;
$id = isset($insertID) && !empty($insertID) ? $insertID : ($updateID ?? null);
// return $this->response->setJSON([
// 'status' => $id ? 'success' : 'error',
// 'message' => $id ? "Ticket Type {$text}d successfully " : "Unable to {$text} ticket type. Please try again." ,
// 'id' => $id
// ])->setStatusCode($id ? 200 : 400);
// }
// return $this->response->setJSON(['status' => 'error','message' => 'No ticket types found'])->setStatusCode(404);
// }
return $this->response->setJSON([
'status' => $id ? 'success' : 'error',
'message' => $id ? "Ticket Type {$text}d successfully" : "Unable to {$text} ticket type. Please try again.",
'id' => $id
])->setStatusCode($id ? 200 : 400);
}
return $this->response->setJSON([ 'status' => 'error', 'message' => 'Invalid request method' ])->setStatusCode(405);
}
catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database' : 'application' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
public function ticketHistoryList()
{
try
{
$data = $this->request->getGet();
$thz_id = $data['thz_id'];
// $details = $this->thzHistoryModal->whereIn('thz_id', $thz_id)->where('is_active', 1)->get()->getResultArray();
$details = $this->thzHistoryModel->select('thz_history.*, CONCAT(user_profiles.first_name, " ", user_profiles.last_name) as created_name')
->join('user_profiles', 'user_profiles.id = thz_history.created_by', 'left')
->where('thz_history.thz_id', $thz_id)->where('thz_history.is_active', 1)
->orderBy('thz_history.created_at', 'desc')
->get()->getResultArray();
if (empty($details)) {
// return $this->response->setJSON([ 'status' => 'error','message' => 'No History found'])->setStatusCode(404);
throw new \RuntimeException('No History found', 404);
}
return $this->response->setJSON(['status' => 'success','data' => $details])->setStatusCode(200);
} catch (\Throwable $e) {
$code = ($e->getCode() && $e->getCode() >= 100 && $e->getCode() < 600) ? $e->getCode() : 500;
$isDbError = $e instanceof \CodeIgniter\Database\Exceptions\DatabaseException
|| $e instanceof \mysqli_sql_exception
|| $e instanceof \PDOException;
$context = ['title' => get_class($e),'type' => get_class($e),'code' => $code,'message' => $e->getMessage(),'file' => $e->getFile(),'line' => $e->getLine()];
$this->myLogger->logme('error', "Exception: {message} in {file} on line {line}", $context, 0);
return $this->response->setJSON([ 'status' => 'error', 'message' => $isDbError ? 'Data Access Error' : $e->getMessage(),
'ref' => $isDbError ? 'database / ' : 'application / ' . $code . ' / ' . $e->getLine()
])->setStatusCode($code);
}
}
/************************************************** PRIVATE FUNCTIONS ********************************************************/

View File

@ -1868,18 +1868,40 @@ class TicketController extends BaseController
public function getPoliciesbyEmpID()
{
$received_data = $this->request->getPost();
$ticket_type_id = $this->request->getPost('ticket_type_id') ?? null;
$emp_id = $received_data['emp_id'];
// Get all client policy IDs for the given employee
$policies = $this->employeePolicyModel
->select('client_policy_id')
->where('employee_id', $emp_id)
->where('is_active', 1)
->where('status', 'active')
->findAll();
if ($ticket_type_id == 1) {
//get the self data for get the all policy list aginst the emp_code
$self_data = $this->employeeModel->where('is_active', 1)->where('id', $emp_id)->first();
$db = db_connect();
$builder = $db->table('employees e');
$builder->select('ep.*');
$builder->join('employee_polices ep', 'e.id = ep.employee_id');
$builder->join('client_policy cp', 'cp.id = ep.client_policy_id AND cp.policy_type_id IN (2,3,4,5)');
$builder->where('e.is_active', 1);
$builder->where('ep.is_active', 1);
$builder->where('e.emp_code', $self_data['emp_code']);
$builder->groupBy('client_policy_id');
$query = $builder->get();
$policies = $query->getResultArray();
} else {
$policies = $this->employeePolicyModel
->select('client_policy_id')
->where('employee_id', $emp_id)
->where('is_active', 1)
->where('status', 'active')
->findAll();
}
// Return empty if no policies found
if (empty($policies)) {
return []; // Return empty if no policies found
return [];
}
// Extract client policy IDs into an array
@ -1902,7 +1924,7 @@ class TicketController extends BaseController
->join('tpa', 'tpa.id = client_policy.tpa_id AND tpa.is_active = 1', 'left')
->where('client_policy.policy_status', 1)
->whereIn('client_policy.id', $policy_ids)
->findAll();
->findAll();
// dd($policyNameandID);
if ($policyNameandID){

View File

@ -123,13 +123,21 @@ class VidalApiController extends BaseController
}
public function newClaim(){
public function newClaim()
{
$postData = $this->request->getPost();
if (empty($postData)) {
return $this->response->setJSON([
'status' => false,
'message' => 'Empty Data Given.',
'data' => $postData
]);
}
helper('api');
$url = ''. getenv('VIDAL_API_BASE_URL').'/submitClaim';
$url = getenv('VIDAL_API_BASE_URL') . '/submitClaim';
$method = 'POST';
$headers = [
@ -138,27 +146,38 @@ class VidalApiController extends BaseController
];
$body = [
'username:' .getenv('VIDAL_API_USERNAME').'',
'password:' .getenv('VIDAL_API_PASSWORD').'',
'PolicyNo:' .$postData['policyNo'] ?? '',
'enrollmentId:' .$postData['enrollmentId'] ?? '',
'typeOfClaim:' .$postData['typeOfClaim'] ?? '',
'claimSubType:' .$postData['claimSubType'] ?? '',
'requestedAmount:' .$postData['requestedAmount'] ?? '',
'ailmentType:' .$postData['ailmentType'] ?? '',
'admissionDate:' .$postData['admissionDate'] ?? '',
'dischargeDate:' .$postData['dischargeDate'] ?? '',
'hospitalName:' .$postData['hospitalName'] ?? '',
'empanelmentNo:' .$postData['empanelmentNo'] ?? '',
'documentType:' .$postData['documentType'] ?? '',
'ailmentName:' .$postData['ailmentName'] ?? '',
'hospitalAddress:' .$postData['hospitalAddress'] ?? '',
'hospitalState:' .$postData['hospitalState'] ?? '',
'hospitalCity:' .$postData['hospitalCity'] ?? '',
'hospitalPinCode:' .$postData['hospitalPinCode'] ?? '',
'hospitalPhoneNo:' .$postData['hospitalPhoneNo'] ?? ''
'username' => getenv('VIDAL_API_USERNAME'),
'password' => getenv('VIDAL_API_PASSWORD'),
'policyNo' => $postData['policyNo'] ?? '',
'enrollmentId' => $postData['enrollmentId'] ?? '',
'typeOfClaim' => $postData['typeOfClaim'] ?? '',
'claimSubType' => $postData['claimSubType'] ?? '',
'requestedAmount' => $postData['requestedAmount'] ?? '',
'ailmentType' => $postData['ailmentType'] ?? '',
'admissionDate' => $postData['admissionDate'] ?? '',
'dischargeDate' => $postData['dischargeDate'] ?? '',
'hospitalName' => $postData['hospitalName'] ?? '',
'empanelmentNo' => $postData['empanelmentNo'] ?? '',
'documentType' => $postData['documentType'] ?? '',
'ailmentName' => $postData['ailmentName'] ?? '',
'hospitalAddress' => $postData['hospitalAddress'] ?? '',
'hospitalState' => $postData['hospitalState'] ?? '',
'hospitalCity' => $postData['hospitalCity'] ?? '',
'hospitalPinCode' => $postData['hospitalPinCode'] ?? '',
'hospitalPhoneNo' => $postData['hospitalPhoneNo'] ?? '',
];
// ✅ Handle file upload
if ($file = $this->request->getFile('File')) {
if ($file->isValid() && !$file->hasMoved()) {
$filePath = $file->getTempName();
$originalName = $file->getClientName();
$mimeType = $file->getMimeType();
$body['File'] = new \CURLFile($filePath, $mimeType, $originalName);
}
}
$response = call_third_party_api($url, $method, $headers, $body);
if($response['status'] != true){
@ -170,10 +189,10 @@ class VidalApiController extends BaseController
}
return $this->response->setJSON($response);
}
public function enrollment(){
$postData = $this->request->getJSON(true);

View File

@ -393,18 +393,18 @@ class ChatbotHelper
<body class="clean-body u_body" style="margin: 0;padding: 0;-webkit-text-size-adjust: 100%;background-color: #F9F9F9;color: #000000">
<!--[if IE]><div class="ie-container"><![endif]-->
<!--[if mso]><div class="mso-container"><![endif]-->
<table style="border-collapse: collapse;table-layout: fixed;border-spacing: 0;mso-table-lspace: 0pt;mso-table-rspace: 0pt;vertical-align: top;min-width: 320px;Margin: 0 auto;background-color: #F9F9F9;width:100%" cellpadding="0" cellspacing="0">
<table data-custom-table-css="table" style="border-collapse: collapse;table-layout: fixed;border-spacing: 0;mso-table-lspace: 0pt;mso-table-rspace: 0pt;vertical-align: top;min-width: 320px;Margin: 0 auto;background-color: #F9F9F9;width:100%" cellpadding="0" cellspacing="0">
<tbody>
<tr style="vertical-align: top">
<td style="word-break: break-word;border-collapse: collapse !important;vertical-align: top">
<!--[if (mso)|(IE)]><table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td align="center" style="background-color: #F9F9F9;"><![endif]-->
<!--[if (mso)|(IE)]><table data-custom-table-css="table" width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td align="center" style="background-color: #F9F9F9;"><![endif]-->
<div class="u-row-container" style="padding: 0px;background-color: transparent">
<div class="u-row" style="margin: 0 auto;min-width: 320px;max-width: 620px;overflow-wrap: break-word;word-wrap: break-word;word-break: break-word;background-color: transparent;">
<div style="border-collapse: collapse;display: table;width: 100%;height: 100%;background-color: transparent;">
<!--[if (mso)|(IE)]><table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><table data-custom-table-css="table" width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table data-custom-table-css="table" cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><td align="center" width="620" style="width: 620px;padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;" valign="top"><![endif]-->
<div class="u-col u-col-100" style="max-width: 320px;min-width: 620px;display: table-cell;vertical-align: top;">
@ -412,12 +412,12 @@ class ChatbotHelper
<!--[if (!mso)&(!IE)]><!-->
<div style="box-sizing: border-box; height: 100%; padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;"><!--<![endif]-->
<table style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<table data-custom-table-css="table" style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<tbody>
<tr>
<td style="overflow-wrap:break-word;word-break:break-word;padding:10px;font-family:times new roman,times;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<table data-custom-table-css="table" width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td style="padding-right: 0px;padding-left: 0px;" align="center">
@ -449,7 +449,7 @@ class ChatbotHelper
<div class="u-row-container" style="padding: 0px;background-color: transparent">
<div class="u-row" style="margin: 0 auto;min-width: 320px;max-width: 620px;overflow-wrap: break-word;word-wrap: break-word;word-break: break-word;background-color: transparent;">
<div style="border-collapse: collapse;display: table;width: 100%;height: 100%;background-color: transparent;">
<!--[if (mso)|(IE)]><table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><table data-custom-table-css="table" width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table data-custom-table-css="table" cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><td align="center" width="620" style="width: 620px;padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;" valign="top"><![endif]-->
<div class="u-col u-col-100" style="max-width: 320px;min-width: 620px;display: table-cell;vertical-align: top;">
@ -457,7 +457,7 @@ class ChatbotHelper
<!--[if (!mso)&(!IE)]><!-->
<div style="box-sizing: border-box; height: 100%; padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;"><!--<![endif]-->
<table style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<table data-custom-table-css="table" style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<tbody>
<tr>
<td style="overflow-wrap:break-word;word-break:break-word;padding:10px;font-family:times new roman,times;" align="left">
@ -492,7 +492,7 @@ class ChatbotHelper
<div class="u-row-container" style="padding: 0px;background-color: transparent">
<div class="u-row" style="margin: 0 auto;min-width: 320px;max-width: 620px;overflow-wrap: break-word;word-wrap: break-word;word-break: break-word;background-color: transparent;">
<div style="border-collapse: collapse;display: table;width: 100%;height: 100%;background-color: transparent;">
<!--[if (mso)|(IE)]><table width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><table data-custom-table-css="table" width="100%" cellpadding="0" cellspacing="0" border="0"><tr><td style="padding: 0px;background-color: transparent;" align="center"><table data-custom-table-css="table" cellpadding="0" cellspacing="0" border="0" style="width:620px;"><tr style="background-color: transparent;"><![endif]-->
<!--[if (mso)|(IE)]><td align="center" width="620" style="width: 620px;padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;" valign="top"><![endif]-->
<div class="u-col u-col-100" style="max-width: 320px;min-width: 620px;display: table-cell;vertical-align: top;">
@ -500,7 +500,7 @@ class ChatbotHelper
<!--[if (!mso)&(!IE)]><!-->
<div style="box-sizing: border-box; height: 100%; padding: 0px;border-top: 0px solid transparent;border-left: 0px solid transparent;border-right: 0px solid transparent;border-bottom: 0px solid transparent;border-radius: 0px;-webkit-border-radius: 0px; -moz-border-radius: 0px;"><!--<![endif]-->
<table style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<table data-custom-table-css="table" style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<tbody>
<tr>
<td style="overflow-wrap:break-word;word-break:break-word;padding:10px;font-family:times new roman,times;" align="left">
@ -514,7 +514,7 @@ class ChatbotHelper
</tbody>
</table>
<table style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<table data-custom-table-css="table" style="font-family:times new roman,times;" role="presentation" cellpadding="0" cellspacing="0" width="100%" border="0">
<tbody>
<tr>
<td style="overflow-wrap:break-word;word-break:break-word;padding:10px;font-family:times new roman,times;" align="left">

View File

@ -322,6 +322,7 @@ class MailHelper
$from_address = isset($params['from_mail']) && !empty($params['from_mail']) ? $params['from_mail'] : getenv('email.fromEmail');
// $from_address = "claims@nhanceindia.in";
if(isset($params['common'])){ $params['common']['from_mail'] = $from_address; }
try {
$curl = curl_init();

View File

@ -59,6 +59,7 @@ if (!function_exists('call_third_party_api')) {
}
$decoded = json_decode($response, true);
return [
'status' => ($httpCode >= 200 && $httpCode < 300),
'data' => $decoded ?: $response, // fallback to raw response

View File

@ -305,7 +305,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -442,7 +442,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . ' ( Payable By Employee ) </h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -479,7 +479,7 @@ class sendMailNotification
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Center align for table header and body
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -655,7 +655,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -741,7 +741,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . ' ( Payable By Employee ) </h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -779,7 +779,7 @@ class sendMailNotification
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Center align for table header and body
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -956,7 +956,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -1042,7 +1042,7 @@ class sendMailNotification
}
$table_content .= $policy_name_for_policy_type . ' ( Payable By Employee ) </h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Add text-align: center to the table head
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -1079,7 +1079,7 @@ class sendMailNotification
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
// Center align for table header and body
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
@ -1332,7 +1332,7 @@ class sendMailNotification
// Start table row
$table_content .= $policy_name . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';
$table_content .= '<th>Name</th>';
@ -1384,7 +1384,7 @@ class sendMailNotification
// Generate summary table for addon if applicable
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';
@ -1482,7 +1482,7 @@ class sendMailNotification
// Start table row
$table_content .= $policy_name . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';
$table_content .= '<th>Name</th>';
@ -1534,7 +1534,7 @@ class sendMailNotification
// Generate summary table for addon if applicable
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';
@ -1630,7 +1630,7 @@ class sendMailNotification
// Start table row
$table_content .= $policy_name . '</h4></div>';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';
$table_content .= '<th>Name</th>';
@ -1683,7 +1683,7 @@ class sendMailNotification
if (count($Addon_list) > 0) {
$table_content .= '<br><div style="text-align: left; font-size: 12px;"><div style="text-align:left;">';
$table_content .= '<table border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<table data-custom-table-css="table" border="1" cellpadding="5" cellspacing="0" style="width:100%; border-collapse: collapse; font-size: 12px;">';
$table_content .= '<thead style="background-color: #02a8b5; color: #ffffff; text-align: center;">';
$table_content .= '<tr>';

View File

@ -25,6 +25,7 @@ class BatchFileModel extends Model
"status",
"error_data",
"client_branch_id",
"policy_issue_date",
];
// Callbacks

View File

@ -7,5 +7,5 @@ use CodeIgniter\Model;
class GmailSentHistoryModel extends Model{
protected $table = 'gmail_sent_history';
protected $primaryKey = 'id';
protected $allowedFields = ["id", "mail", "bcc", "cc", "message", "attachments", "client_id", "client_branch_id", "client_policy_id", "employee_policy_id", "employee_id", "mail_type", "gmail_api_status", "gmail_api_id", "created_by", "created_at", "updated_by", "updated_at", "isactive","received_message"];
protected $allowedFields = ["id", "mail", "bcc", "cc", "message", "attachments", "client_id", "client_branch_id", "client_policy_id", "employee_policy_id", "employee_id", "mail_type", "gmail_api_status", "gmail_api_id", "module", "pk", "from_mail", "created_by", "created_at", "updated_by", "updated_at", "isactive","received_message", "common"];
}

View File

@ -101,6 +101,10 @@ class LeadsModel extends Model
'total_lives_at_incept',
'premium_at_incept',
'next_reminder_date',
'is_insurer_auto_mail',
'quote_received_insurer',
];

View File

@ -33,7 +33,9 @@ class LevelContactModel extends Model
->select('
level_contacts.id,
insurers.short_name as insurer_name,
insurers.id as insurer_id,
insurer_branch.branch_code,
insurer_branch.id as insurer_branch_id,
level_contacts.name as contact_person_name,
level_contacts.email as contact_person_email
')
@ -51,7 +53,7 @@ class LevelContactModel extends Model
$query->where('insurer_branch.insurer_id', $insurer_id);
}
$result = $query->get()->getResultArray();
$result = $query->orderBy('insurers.id')->get()->getResultArray();
return $result;
}

View File

@ -0,0 +1,45 @@
<?php
namespace App\Models;
use CodeIgniter\Model;
class ThzHistoryModel extends Model
{
protected $table = 'thz_history';
protected $primaryKey = 'id';
protected $useAutoIncrement = true;
protected $returnType = 'array';
protected $useSoftDeletes = false;
protected $protectFields = true;
protected $allowedFields = ['thz_id','field_name','display_name','old_value','new_value','created_by','created_at','is_active'];
protected bool $allowEmptyInserts = false;
// Dates
protected $useTimestamps = false;
protected $dateFormat = 'datetime';
protected $createdField = 'created_at';
protected $updatedField = 'updated_at';
protected $deletedField = 'deleted_at';
// Validation
protected $validationRules = [];
protected $validationMessages = [];
protected $skipValidation = false;
protected $cleanValidationRules = true;
// Callbacks
protected $allowCallbacks = true;
protected $beforeInsert = [];
protected $afterInsert = [];
protected $beforeUpdate = [];
protected $afterUpdate = [];
protected $beforeFind = [];
protected $afterFind = [];
protected $beforeDelete = [];
protected $afterDelete = [];
}

View File

@ -4,9 +4,9 @@ namespace App\Models;
use CodeIgniter\Model;
class TicketTypesModel extends Model
class ThzTypeModel extends Model
{
protected $table = 'ticket_types';
protected $table = 'thz_type';
protected $primaryKey = 'id';
protected $useAutoIncrement = true;
protected $returnType = 'array';

View File

@ -221,7 +221,7 @@
<img src="<?= base_url() . "public"; ?>/assets/images/active_pending_actions.png" alt="Logo" height="14"
class="active_pending" style="display:none;">
&nbsp;&nbsp;
<span class="d-none d-sm-inline-block dash-tab">Pending Actions</span>
<span class="d-none d-sm-inline-block dash-tab dash-tab-font">Pending Actions</span>
</a>
</li>
&nbsp;&nbsp;&nbsp;&nbsp;
@ -235,7 +235,7 @@
<img src="<?= base_url() . "public"; ?>/assets/images/active_bds.png" alt="Logo" height="14"
class="active_bds " style="display:none;">
&nbsp;&nbsp;
<span class="d-none d-sm-inline-block dash-tab">BDS</span>
<span class="d-none d-sm-inline-block dash-tab dash-tab-font">BDS</span>
</a>
</li>
&nbsp;&nbsp;&nbsp;&nbsp;
@ -251,7 +251,7 @@
<img src="<?= base_url() . "public"; ?>/assets/images/active_claims.png" alt="Logo" height="14"
class="active_claims " style="display:none;">
&nbsp;&nbsp;
<span class="d-none d-sm-inline-block dash-tab">Claims</span>
<span class="d-none d-sm-inline-block dash-tab dash-tab-font">Claims</span>
</a>
</li>
&nbsp;&nbsp;&nbsp;&nbsp;
@ -266,7 +266,7 @@
<img src="<?= base_url() . "public"; ?>/assets/images/active_leads_and_bds_renewal.png" alt="Logo" height="14"
class="active_leads " style="display:none;">
&nbsp;&nbsp;
<span class="d-none d-sm-inline-block dash-tab">Leads and BDS Renewals</span>
<span class="d-none d-sm-inline-block dash-tab dash-tab-font">Leads and BDS Renewals</span>
</a>
</li>
&nbsp;&nbsp;&nbsp;&nbsp;

View File

@ -249,7 +249,7 @@ table.dataTable tbody td {
<h4 style="position: relative;">User List</h4>
</div>
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">Name</th>
@ -383,7 +383,7 @@ table.dataTable tbody td {
<!-- Tooltip container separate from trigger -->
<div class="tooltip-container" id="tooltipContainer">
<div class="tooltip" id="accessMatrixTooltip">
<table class="tooltip-table" style="color: black;">
<table data-custom-table-css="table" class="tooltip-table" style="color: black;">
<thead>
<tr>
<th>Team</th>
@ -475,7 +475,7 @@ table.dataTable tbody td {
<div class="tooltip-container" id="roleTooltipContainer">
<div class="tooltip" id="roleAccessMatrixTooltip">
<table class="tooltip-table" style="color: black;">
<table data-custom-table-css="table" class="tooltip-table" style="color: black;">
<thead>
<tr>
<th>Team</th>

View File

@ -30,7 +30,7 @@ table.dataTable thead th {
<a data-toggle="modal" data-target="#bike_make_login-modal" href="#" type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" data-toggle="" data-placement="top" title="Add" data-trigger="hover">ADD</a>
</div>
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -25,7 +25,7 @@
</div>
<div class="table-responsive">
<table id="datatable-buttons" class="table table-hover m-0 table-centered dt-responsive w-100">
<table data-custom-table-css="table" id="datatable-buttons" class="table table-hover m-0 table-centered dt-responsive w-100">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">SNO</th>

View File

@ -33,7 +33,7 @@
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead>
<tr>
<?php

View File

@ -20,7 +20,7 @@ table.dataTable tbody td {
</div>
<div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>

View File

@ -30,7 +30,7 @@ table.dataTable tbody td {
</div>
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>Insurer</th>

View File

@ -30,7 +30,7 @@ table.dataTable tbody td {
</div>
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>Insurer</th>

View File

@ -33,7 +33,7 @@
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead>
<tr>
<?php

View File

@ -179,7 +179,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive" style="overflow-x: auto;">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S.No</th>

View File

@ -66,7 +66,7 @@ table.dataTable thead th {
data-trigger="hover">ADD</button> -->
</div>
</div>
<table id="scroll-horizontal-datatable" class="table w-100 nowrap" >
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap" >
<thead class="bg-light">
<tr>
<th class="font-weight-medium">S.No.</th>

View File

@ -68,7 +68,7 @@
</div>
</div>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">SNO</th>

View File

@ -45,7 +45,7 @@
</div>
<div class="table-responsive" style="overflow-x: auto;">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S.No</th>

View File

@ -33,7 +33,7 @@
</div>
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<?php if ($policy_type != 1) {?>
<tr>

View File

@ -29,7 +29,7 @@
</div>
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th style="text-align: center;" colspan="8">OPEN</th>

View File

@ -44,7 +44,7 @@
</div> -->
</div>
<!-- <div class="table-responsive">
<table class="table table-bordered table-striped">
<table data-custom-table-css="table" class="table table-bordered table-striped">
<tr>
<td>Get Individual Employee Data</td>
<td><?= base_url("getEmpData") ?></td>

View File

@ -54,7 +54,7 @@
<div class="table-responsive" id="branch_table">
<table class="table table-borderless table-nowrap mb-0">
<table data-custom-table-css="table" class="table table-borderless table-nowrap mb-0">
<thead class="thead-light">
<tr>
<th>Branch Name</th>

View File

@ -16,7 +16,7 @@
<a href="<?= base_url("client/client_deposit"); ?>" type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" data-toggle="" data-placement="top" title="Add" data-trigger="hover">ADD</a>
</div> -->
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -39,7 +39,7 @@
<!--
<div class="col-6">
<table>
<table data-custom-table-css="table">
<tr>
<td style="font-size: 18px;"></td>
</tr>
@ -48,7 +48,7 @@
<div class="col-6">
<table>
<table data-custom-table-css="table">
<tr>
<td style="font-size: 18px;"> <strong> Relationship Manager </strong></td>
</tr>
@ -63,7 +63,7 @@
<div class="row">
<!-- <div class="col-6">
<table>
<table data-custom-table-css="table">
<tr>
<td style="padding: 3px;"></td>
</tr>
@ -74,7 +74,7 @@
</div> -->
<div class="col-6">
<table>
<table data-custom-table-css="table">
<tr>
<td style="padding: 3px;"><label> Account Manager :
</label> <?= implode(', ', $account_managers) ?></td>
@ -120,7 +120,7 @@
<div id="collapseTwo" class="collapse show" aria-labelledby="headingOne" data-parent="#accordion">
<div class="card-body" style="position: relative;bottom: 25px;">
<div class="row">
<table class="table table-hover m-0 table-centered dt-responsive nowrap w-100"
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive nowrap w-100"
cellspacing="0">
<thead class="bg-light">
<tr>
@ -205,7 +205,7 @@
<div id="collapseThree" class="collapse show" aria-labelledby="headingOne" data-parent="#accordion">
<div class="card-body" style="position: relative;bottom: 25px;">
<div class="row">
<table id="tb1" class="table table-hover m-0 table-centered dt-responsive nowrap w-100"
<table data-custom-table-css="table" id="tb1" class="table table-hover m-0 table-centered dt-responsive nowrap w-100"
cellspacing="0">
<thead class="bg-light">
<tr>

View File

@ -9,7 +9,7 @@
<div class="card">
<div class="card-body">
<div class="table-responsive">
<table id="kyc_table" class="table table-sm mb-0">
<table data-custom-table-css="table" id="kyc_table" class="table table-sm mb-0">
<thead>
<tr>
<th>Document Name</th>
@ -70,7 +70,7 @@
<div class="card">
<div class="card-body">
<div class="table-responsive">
<table id="kyc_table" class="table table-sm mb-0">
<table data-custom-table-css="table" id="kyc_table" class="table table-sm mb-0">
<thead>
<tr>
<th>Document Name</th>
@ -310,7 +310,7 @@
<td>${item.other_docs_name}</td>
<td>${item.file_name}</td>
<td>
<a href = "${url}" data-id="${item.id}" class="fa fa-download" style="font-size:18px;" download></a>
<a href = "${url}" data-id="${item.id}" class="mdi mdi-download" style="font-size:18px;" download></a>
</td>
</tr>
`;
@ -424,7 +424,7 @@
</td>
<td id="name_${item.id}" style="display:none;"></td>
<td>
<a id="download_${item.id}" data-id="${item.id}" class="fa fa-download" style="font-size:18px; display: none" download></a>
<a id="download_${item.id}" data-id="${item.id}" class="mdi mdi-download" style="font-size:18px; display: none" download></a>
</td>
</tr>`;
tbody.append(row);
@ -480,7 +480,7 @@
<td>${item.other_docs_name}</td>
<td>${item.file_name}</td>
<td>
<a href = "${url}" data-id="${item.id}" class="fa fa-download" style="font-size:18px;" target="_blank"></a>
<a href = "${url}" data-id="${item.id}" class="mdi mdi-download" style="font-size:18px;" target="_blank"></a>
</td>
</tr>
`;

View File

@ -65,7 +65,7 @@ table.dataTable thead th {
<a href="<?= base_url("client/create"); ?>" type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" data-toggle="" data-placement="top" title="Add" data-trigger="hover">Add</a>
</div> -->
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -28,7 +28,7 @@
</div>
<div class="table-responsive" id="table_list">
<table class="table table-borderless table mb-0" id="table-client-policy">
<table data-custom-table-css="table" class="table table-borderless table mb-0" id="table-client-policy">
<thead class="thead-light">
<tr>
<th>Insurer</th>
@ -425,7 +425,7 @@
// Conditionally render the delete option based on the role
if (role !== 3 && role !== 4) {
policyTable += `
<a href="#" data-id="${item.id}" id="${search_term}" data-typeid="${item.policy_type_id}" class="dropdown-item" onclick="removepolicy(this)"><i class="fa fa-trash mr-2 text-muted font-18 vertical-middle"></i>Delete</a>`;
<a href="#" data-id="${item.id}" id="${search_term}" data-typeid="${item.policy_type_id}" class="dropdown-item" onclick="removepolicy(this)"><i class="mdi mdi-delete mr-2 text-muted font-18 vertical-middle"></i>Delete</a>`;
}
policyTable += `

View File

@ -99,7 +99,7 @@
</div>
<div class="table-responsive" style="overflow-x: auto;">
<table id="scroll-horizontal-datatable" class="table w-100">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100">
<thead class="bg-light">
<tr>
<th>S.No</th>
@ -118,7 +118,7 @@
<td>
<a id="download_1"
data-id="1"
class="fa fa-download"
class="mdi mdi-download"
style="font-size: 18px;"
target="_blank"
href="<?= base_url("/downloadGdriveFile?client_id=" . $row['client_id'] . "&file_type=" . $row['file_type'] . "&file_name=" . $row['file_name']."&client_policy_id=".$row['client_policy_id']); ?>">

View File

@ -45,7 +45,7 @@
</div>
<div class="table-responsive" style="overflow-x: auto;">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S.No</th>

View File

@ -15,7 +15,7 @@
<body>
<table>
<table data-custom-table-css="table">
<?php if(isset($data)) { ?>
<?php foreach ($data as $key => $value) { ?>
<tr>

View File

@ -17,7 +17,7 @@
<body>
<table style="width: 100%;">
<table data-custom-table-css="table" style="width: 100%;">
<?php if(isset($data)) { ?>
<?php foreach ($data as $key => $value) { ?>
@ -36,7 +36,7 @@
<div style="display: flex;gap: 20px;">
<table>
<table data-custom-table-css="table">
<tr>
<td>

View File

@ -8,7 +8,7 @@
</head>
<body>
<table style="width: 100%;">
<table data-custom-table-css="table" style="width: 100%;">
<?php if(isset($data)) { ?>
<?php foreach ($data as $key => $value) { ?>
@ -25,7 +25,7 @@
<div style="display: flex;gap: 20px; padding-top: 10px;">
<table>
<table data-custom-table-css="table">
<tr>
<td>

View File

@ -12,7 +12,7 @@
POLICY</span></div>
</div>
<table
<table data-custom-table-css="table"
style="font-family: sans-serif;font-size: 14px;width: 100%;margin-top: 20px;margin-left: 20px;line-height: 20px;">
<tbody>
<tr>
@ -40,7 +40,7 @@
<div style="border: 1px solid black;width: 400px;max-height: 300px;padding: 5px;">
<div style="font-size: 11px;text-align: center;">The card is for identification purpose only</div>
<table style="width: 100%;text-align: center;font-size: 11px;">
<table data-custom-table-css="table" style="width: 100%;text-align: center;font-size: 11px;">
<tbody>
<tr>
<td>General & Claim Enquiry Helpline</td>
@ -50,7 +50,7 @@
</table>
<table style="font-size: 11px;width: 100%;text-align: center;">
<table data-custom-table-css="table" style="font-size: 11px;width: 100%;text-align: center;">
<tbody>
<tr>
<td style="border: 1px solid black;">Toll Free : 1800-209-7777 <br>Email :
@ -63,7 +63,7 @@
<div style="font-size: 14px;text-align: center;">CITI MDIndia branch contact</div>
<div>
<table style="text-align: center;width: 100%;font-size: 12px;">
<table data-custom-table-css="table" style="text-align: center;width: 100%;font-size: 12px;">
<thead>
<tr>
<th style="border: 1px solid black;">Center</th>

View File

@ -89,7 +89,7 @@
<h4 style="position: relative;">Employees</h4>
</div>
</div>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">SNO</th>
@ -670,7 +670,7 @@
let historyTable = `
<div class="card-body">
<div class="table-responsive">
<table class="table w-100">
<table data-custom-table-css="table" class="table w-100">
<thead class="bg-light">
<tr>
<th>Field</th>

View File

@ -374,7 +374,7 @@ function getPendingActionClientDataForDashboard(input, headerName, type)
var link = '<?=base_url()?>';
if (res.data.length !== 0) {
// table = `<table class="table table-striped table-sm table-centered mb-0"><tbody>`;
// table = `<table data-custom-table-css="table" class="table table-striped table-sm table-centered mb-0"><tbody>`;
div = `<div class="row">`;
$.each(res.data, function(index, item) {

View File

@ -87,7 +87,7 @@
</div>
</div>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">SNO</th>
@ -163,7 +163,7 @@
</div>
<div class="modal-body" id="modal_body">
<div class="table-responsive">
<table class="table table-hover mb-0">
<table data-custom-table-css="table" class="table table-hover mb-0">
<thead id="table_head_data">
</thead>

View File

@ -181,7 +181,7 @@
<div class="col-12">
<div class="card">
<div class="card-body">
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th class="font-weight-medium">SNO</th>

View File

@ -86,7 +86,7 @@ $errorId = uniqid('error', true);
<?php $argsId = $errorId . 'args' . $index ?>
( <a href="#" onclick="return toggle('<?= esc($argsId, 'attr') ?>');">arguments</a> )
<div class="args" id="<?= esc($argsId, 'attr') ?>">
<table cellspacing="0">
<table data-custom-table-css="table" cellspacing="0">
<?php
$params = null;
@ -138,7 +138,7 @@ $errorId = uniqid('error', true);
<h3>$<?= esc($var) ?></h3>
<table>
<table data-custom-table-css="table">
<thead>
<tr>
<th>Key</th>
@ -168,7 +168,7 @@ $errorId = uniqid('error', true);
<?php if (! empty($constants['user'])) : ?>
<h3>Constants</h3>
<table>
<table data-custom-table-css="table">
<thead>
<tr>
<th>Key</th>
@ -197,7 +197,7 @@ $errorId = uniqid('error', true);
<div class="content" id="request">
<?php $request = Services::request(); ?>
<table>
<table data-custom-table-css="table">
<tbody>
<tr>
<td style="width: 10em">Path</td>
@ -243,7 +243,7 @@ $errorId = uniqid('error', true);
<h3>$<?= esc($var) ?></h3>
<table style="width: 100%">
<table data-custom-table-css="table" style="width: 100%">
<thead>
<tr>
<th>Key</th>
@ -281,7 +281,7 @@ $errorId = uniqid('error', true);
<h3>Headers</h3>
<table>
<table data-custom-table-css="table">
<thead>
<tr>
<th>Header</th>
@ -307,7 +307,7 @@ $errorId = uniqid('error', true);
$response->setStatusCode(http_response_code());
?>
<div class="content" id="response">
<table>
<table data-custom-table-css="table">
<tr>
<td style="width: 15em">Response Status</td>
<td><?= esc($response->getStatusCode() . ' - ' . $response->getReasonPhrase()) ?></td>
@ -320,7 +320,7 @@ $errorId = uniqid('error', true);
<h3>Headers</h3>
<table>
<table data-custom-table-css="table">
<thead>
<tr>
<th>Header</th>
@ -354,7 +354,7 @@ $errorId = uniqid('error', true);
<!-- Memory -->
<div class="content" id="memory">
<table>
<table data-custom-table-css="table">
<tbody>
<tr>
<td>Memory Usage</td>

View File

@ -68,7 +68,7 @@ table.dataTable tbody td {
<!-- <button><a href="">download full file</a></button> -->
<div class="container">
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<?php foreach ($excel_header as $header): ?>

View File

@ -68,7 +68,7 @@ table.dataTable tbody td {
<!-- <button><a href="">download full file</a></button> -->
<div class="container">
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<?php foreach ($excel_header as $header): ?>

View File

@ -19,7 +19,7 @@
</div>
</div>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -179,7 +179,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive" style="overflow-x: auto;">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S.No</th>

View File

@ -38,7 +38,7 @@ table.dataTable tbody td {
</div>
</div>
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S. No</th>

View File

@ -99,7 +99,7 @@
</div>
</div>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0"
id="hr_tickets_table">
<thead class="bg-light">
<tr>

View File

@ -6,7 +6,7 @@
<div class="table-responsive" id="branch_table" >
<table class="table table-borderless table-nowrap mb-0">
<table data-custom-table-css="table" class="table table-borderless table-nowrap mb-0">
<thead class="thead-light">
<tr>
<th>Branch Name</th>

View File

@ -74,7 +74,7 @@
<div class="table-responsive" id="branch_table" >
<table class="table table-borderless table-nowrap mb-0">
<table data-custom-table-css="table" class="table table-borderless table-nowrap mb-0">
<thead class="thead-light">
<tr>
<th>S.NO</th>

View File

@ -49,7 +49,7 @@
<h4 style="position: relative;">Insurer List</h4>
</div>
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -90,9 +90,15 @@
</select>
</div>
</div>
<div class="form-row policy_issue_date_row" style="display:none;">
<div class="form-group col-md-4">
<label id="policy_issue_date_label">Policy Issue Date</label> <br />
<input type="text" class="form-control" id="policy_issue_date" name="policy_issue_date"
placeholder="Enter Policy Issue Date">
</div>
</div>
<br>
<div class="form-row" id="import_excel_btn">
<div class="form-group col-md-3">
<label>Upload file</label>&nbsp;[ <a id="import_excel_download" data-toggle="tooltip" data-placement="top" title="Download Import Sample Excel" style="display: none;">Sample Excel</a> ]
@ -144,6 +150,16 @@
});
$(document).ready(function() {
var policy_issue_datePicker = flatpickr("#policy_issue_date", {
dateFormat: "d/m/Y",
allowInput: false,
});
$('#insurer_or_tpa, #action_type').on('change', togglePolicyIssueDate);
});
$(document).ready(function() {
<?php if (session()->has('error')) : ?>
@ -730,4 +746,19 @@
//------------------------------------------------------------------------------------------------------
</script>
<script>
function togglePolicyIssueDate() {
let insurer = $('#insurer_or_tpa').val();
let action = $('#action_type').val();
if (insurer === 'insurer' && action === 'import') {
$('.policy_issue_date_row').show();
$('#policy_issue_date').attr('required', true);
$('#policy_issue_date_label').html('Policy Issue Date <span class="text-danger">*</span>');
} else {
$('.policy_issue_date_row').hide();
$('#policy_issue_date').removeAttr('required').val('');
$('#policy_issue_date_label').text('Policy Issue Date');
}
}
</script>

View File

@ -175,7 +175,7 @@ table.dataTable tbody td {
</div><div class="dataTables_length d-flex align-items-center">
</div>
<div>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th></th>
@ -425,7 +425,7 @@ table.dataTable tbody td {
<button type="button" id="add_row_btn" class="btn btn-secondary float-right"><i class="fa fa-plus"></i></button>
<table class="table table-bordered" id="payment_table_modal">
<table data-custom-table-css="table" class="table table-bordered" id="payment_table_modal">
<thead>
<tr>
<th style="display: none;">pk</th>
@ -445,7 +445,7 @@ table.dataTable tbody td {
<td><input type="number" class="form-control" name="tds[]" placeholder="Enter TDS" onchange="checkInvAmont(event)" required></td>
<td><input type="text" class="form-control" name="utr_no[]" placeholder="Enter UTR No" required></td>
<td><input type="text" class="form-control payment_date" name="payment_date[]" value="<?php echo date('d/m/Y'); ?>" placeholder="dd/mm/yyyy" required readonly></td>
<td><i class="fa fa-trash mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
<td><i class="mdi mdi-delete mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
</tr>
</tbody>
</table>
@ -728,7 +728,7 @@ document.addEventListener("DOMContentLoaded", function () {
<td><input type="number" class="form-control" name="tds[]" placeholder="Enter TDS" onchange="checkInvAmont(event)" required></td>
<td><input type="text" class="form-control" name="utr_no[]" placeholder="Enter UTR No" required></td>
<td><input type="text" class="form-control payment_date" value="<?php echo date('d/m/Y'); ?>" name="payment_date[]" placeholder="dd/mm/yyyy" required readonly></td>
<td><i class="fa fa-trash mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
<td><i class="mdi mdi-delete mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
`;
tableBody.appendChild(newRow);
@ -871,7 +871,7 @@ function showInvoiceStatusModal(event)
<td><input type="number" class="form-control" name="tds[]" placeholder="Enter Amount" value="${payment.tds}" onchange="checkInvAmont(event)" required></td>
<td><input type="text" class="form-control" name="utr_no[]" placeholder="Enter UTR No" value="${payment.utr_no}" required></td>
<td><input type="text" class="form-control payment_date" name="payment_date[]" value="${formatDateToDMY(payment.received_date)}" required readonly></td>
<td><i class="fa fa-trash mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
<td><i class="mdi mdi-delete mr-2 font-18 vertical-middle text-danger remove-row" style="text-align: center;"></i></td>
`;
});
}

View File

@ -32,7 +32,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th></th>

View File

@ -32,7 +32,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S. No</th>

View File

@ -6,7 +6,7 @@
<div class="table-responsive" id="branch_table" >
<table class="table table-borderless table-nowrap mb-0" id="table-kyc-docs">
<table data-custom-table-css="table" class="table table-borderless table-nowrap mb-0" id="table-kyc-docs">
<thead class="thead-light">
<tr>
<th>File Name</th>

View File

@ -49,7 +49,7 @@
<h4 style="position: relative;">KYC List</h4>
</div>
</div>
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -97,17 +97,7 @@
<!-- <script src="<?= base_url('public/unlayer/js/embed.js') . '' ?>"></script> -->
<!-- srinivas -->
<style>
body[data-sidebar-size=condensed]:not([data-layout=compact]):not(.auth-fluid-pages) {
min-height: 0;
}
body[data-sidebar-size=condensed] .navbar-custom {
left: 155px !important;
}
body[data-sidebar-size=condensed] .logo-box {
width: 155px !important;
}
.navbar-custom {
top: -10px !important;
@ -249,7 +239,7 @@
/* Force all text across the entire app to black */
html, body, * {
color: #000 !important;
/* color: #000 !important; */
}
@ -496,7 +486,7 @@
<style>
*{
font-family: Inter, sans-serif !important;
font-family: 'Poppins' !important;
}
.content{
min-height: 70vh;
@ -545,14 +535,20 @@ rgba(0, 153, 158, 0.5) (transparent)
font-style: normal;
font-size: 30px;
line-height: 1;
letter-spacing: 0;
letter-spacing: 0;
color:black;
}
.sub-title-text {
font-weight: 500;
font-style: normal;
font-size: 18px;
line-height: 1;
letter-spacing: 0;
letter-spacing: 0;
color:black;
}
.font-color-black{
color:black;
}
.app-text-left {
@ -583,7 +579,7 @@ rgba(0, 153, 158, 0.5) (transparent)
a.app-text-primary:hover, a.app-text-primary:focus {
color: rgba(0, 153, 158, 0.5); !important; }
color: rgba(0, 153, 158, 0.5) !important; }
a.app-text-secondary:hover, a.app-text-secondary:focus {
color: rgba(226, 103, 40, 0.5) !important; }
@ -665,10 +661,77 @@ a.app-badge-secondary:focus, a.app-badge-secondary.focus {
outline: 0;
box-shadow: 0 0 0 0.15rem rgba(226, 103, 40, 0.5); }
table[data-custom-table-css="table"] thead th {
background-color: #00999E;
color: #fff !important;
border-top: 0px solid #fff !important;
border-bottom: 0px solid #fff !important;
}
table[data-custom-table-css="table"] tbody td {
background: #F5FFFF;
padding: 12px;
border-top: 0px solid #fff !important;
border-bottom: 2px solid #C3EDEE !important;
}
table[data-custom-table-css="table"] thead th:first-child {
border-top-left-radius: 15px !important;
border-bottom-left-radius: 15px !important;
}
table[data-custom-table-css="table"] thead th:last-child {
border-top-right-radius: 15px !important;
border-bottom-right-radius: 15px !important;
}
table[data-custom-table-css="table"] tbody tr td:first-child {
border-top-left-radius: 15px !important;
border-bottom-left-radius: 15px !important;
}
table[data-custom-table-css="table"] tbody tr td:last-child {
border-top-right-radius: 15px !important;
border-bottom-right-radius: 15px !important;
}
table[data-custom-table-css="table"] tbody tr:hover td {
background-color: #e0e0e0;
}
table[data-custom-table-css="table"] {
border-collapse: separate !important;
border-spacing: 0 8px !important;
width: 100%;
}
</style>
<style>
label{
font-weight: 500 !important;
font-size:0.875rem !important;
}
.dataTables_info , .text , #client_logo{
font-weight: 500 !important;
color:#000 !important;
}
.right-bar{
right : -300px;
}
.dash-tab-font{
font-weight: 500 !important;
font-size:0.875rem !important;
}
.jodit-wysiwyg{
color:black;
}
</style>
@ -855,7 +918,7 @@ a.app-badge-secondary:focus, a.app-badge-secondary.focus {
</li>
<?php } ?>
<!-- Tickets -->
<?php if (in_array(get_role_id(), [1,2,3,5]) || in_array(CLAIMS_TEAM_ID, user_team())) { ?>
<?php if (in_array(get_role_id(), [1,2,3,4,5]) || in_array(CLAIMS_TEAM_ID, user_team())) { ?>
<li>
<a id="tickets" href="<?= base_url('/ticketList?return_type=web') ?>" class="waves-effect img-inactive-not-working">
<img src="<?= base_url() . "public"; ?>/assets/images/ticket.png" alt="Logo" height="20">

View File

@ -332,6 +332,20 @@
</select>
</div>
<div class="form-group col-md-3">
<label for="">Next Reminder Date<span class="text-danger"></span></label>
<input type="text" class="form-control" id="next_reminder_date" name="next_reminder_date" placeholder="DD/MM/YYYY">
</div>
<div class="form-group col-md-3">
<label class="switch" style="position: relative;top: 33px;left: 0px;">
<input id="is_insurer_auto_mail" type="checkbox" name="is_insurer_auto_mail">
<span class="slider round" style="height: 27px;"></span>
</label>
<label for="is_insurer_auto_mail" style="position: relative;top: 35px;left: 20px;">Insurer Auto Mail</label>
</div>
</div>
<div class="form-row">
@ -556,6 +570,12 @@
console.log('---- completed ----')
var next_reminder_date = flatpickr("#next_reminder_date", {
dateFormat: "d/m/Y",
allowInput: false,
maxDate: "today"
});
})
//------------------------------ GET DATA ( EDIT, BRANCH, POLICY ) ---------------------------------------------------------------------------

View File

@ -823,6 +823,13 @@ if (isset($selected_lead_type)) {
$('#entity_type_id').val(data.entity_type_id || '');
$('#lead_status').val(data.status || '');
$('#notes').val(data.notes || '');
$('#next_reminder_date').val(data.next_reminder_date || '');
if (data.is_insurer_auto_mail == 1) {
$('#is_insurer_auto_mail').prop('checked', true);
} else {
$('#is_insurer_auto_mail').prop('checked', false);
}
// setTimeout(() => {
// $('#client_id').val(data.client_id || '').change();
@ -1144,7 +1151,5 @@ if (isset($selected_lead_type)) {
});
}
</script>
<?php } ?>

View File

@ -160,7 +160,7 @@ table.dataTable tbody td {
</div>
<div>
<div class="table-responsive">
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
@ -215,6 +215,12 @@ table.dataTable tbody td {
</a>
<?php } ?>
<?php } ?>
<a href="javascript:void(0);"
class="dropdown-item btnHistory app-text-black"
data-id="<?= $row['id']; ?>"
title="Click to view Mail History">
<i class="mdi mdi-history mr-2 text-muted font-18 vertical-middle"></i>Email History
</a>
</div>
</div>
</td>
@ -266,6 +272,22 @@ table.dataTable tbody td {
</div>
</div>
<div class="modal fade app-font-family" id="EmailModal" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered modal-xl" style="max-width: 1140px !important;">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Email History</h4>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
</div>
<div class="modal-body history-container" style="padding:11px !important;">
</div>
</div>
</div>
</div>
<script>
document.addEventListener("DOMContentLoaded", function () {
@ -442,6 +464,146 @@ document.addEventListener("DOMContentLoaded", function () {
}
</script>
<script>
document.addEventListener("click", function(e) {
if (e.target.closest(".btnHistory")) {
let lead_id = e.target.closest(".btnHistory").dataset.id;
console.log("*********" + lead_id);
let url = '<?= base_url('/util/getLeadEmailHistory/') ?>' + lead_id;
console.log("*********" + url);
fetch('<?= base_url('/util/getLeadEmailHistory/') ?>' + lead_id, {
method: "GET",
headers: {
"Accept": "application/json"
}
})
.then(response => response.json())
.then(response => {
let container = document.querySelector(".history-container");
container.innerHTML = ""; // clear old content
if (response.status === "success" && response.data.length > 0) {
console.log("******** 1" + response.status);
let table = `
<div class="table-responsive">
<table data-custom-table-css="table" id="historytable" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th><div class="column-header">S.No.</div></th>
<th><div class="column-header">From Mail</div></th>
<th><div class="column-header">To Mail</div></th>
<th><div class="column-header">BCC</div></th>
<th><div class="column-header">CC</div></th>
<th><div class="column-header">Type</div></th>
<th><div class="column-header">Status</div></th>
<th><div class="column-header">Date/Time</div></th>
</tr>
</thead>
<tbody>
`;
response.data.forEach((row, index) => {
let formattedDate = "-";
let statusValue = "-";
if (row.received_message) {
if (row.received_message.toLowerCase().includes("error")) {
statusValue = "Failed";
} else {
statusValue = "Success";
}
}
if (row.created_at) {
let dt = new Date(row.created_at);
let dateStr = dt.toLocaleDateString("en-GB", {
day: "2-digit",
month: "long",
year: "numeric"
});
let timeStr = dt.toLocaleTimeString("en-US", {
hour: "2-digit",
minute: "2-digit",
hour12: true
}).toLowerCase();
formattedDate = `${dateStr} ${timeStr}`;
}
let fromMails = "-";
if (row.from_mail) {
fromMails = row.from_mail
.split(",") // split by comma
.map(m => m.trim().replace(/^"|"$/g, "")) // trim + remove quotes at start/end
.filter(m => m !== "") // remo
.join("<br>"); // join with line break
}
let toMails = "-";
if (row.mail) {
toMails = row.mail
.split(",")
.map(m => m.trim().replace(/^"|"$/g, ""))
.filter(m => m !== "")
.join("<br>");
}
let ccMails = "-";
if (row.cc && row.cc.trim() !== "") {
ccMails = row.cc
.split(",")
.map(m => m.trim().replace(/^"|"$/g, ""))
.filter(m => m !== "")
.join("<br>");
}
let bccMails = "-";
if (row.bcc && row.bcc.trim() !== "") {
bccMails = row.bcc
.split(",")
.map(m => m.trim().replace(/^"|"$/g, ""))
.filter(m => m !== "")
.join("<br>");
}
table += `
<tr>
<td style="white-space: nowrap !important;">${index + 1}</td>
<td style="white-space: nowrap !important;">${fromMails}</td>
<td style="white-space: nowrap !important;">${toMails}</td>
<td style="white-space: nowrap !important;">${bccMails ? bccMails : '-'}</td>
<td style="white-space: nowrap !important;">${ccMails ? ccMails : '-'}</td>
<td style="white-space: nowrap !important;">${row.mail_type ? row.mail_type.toUpperCase() : '-'}</td>
<td style="white-space: nowrap !important;">${statusValue ? statusValue.toUpperCase() : '-'}</td>
<td style="white-space: nowrap !important;">${formattedDate}</td>
</tr>
`;
});
table += `</tbody></table>`;
container.innerHTML = table;
} else {
console.log("******** 2" + response.status);
container.innerHTML = `
<div class="d-flex justify-content-center align-items-center" style="height: 50vh; width:100%;">
<p class="text-center"><i>${response.message ?? 'No history found'}</i></p>
</div>
`;
}
// show modal (if using Bootstrap 5)
let EmailModal = new bootstrap.Modal(document.getElementById("EmailModal"));
EmailModal.show();
})
.catch(error => {
console.log("******** 3" + error);
document.querySelector(".history-container").innerHTML = `
<div class="d-flex justify-content-center align-items-center" style="height: 50vh; width:100%;">
<p class="text-center"><i>No Data Found</i></p>
</div>
`;
let EmailModal = new bootstrap.Modal(document.getElementById("EmailModal"));
EmailModal.show();
console.error(error);
});
}
});
</script>
<script>
function selectOption(element, radioId) {
// Remove selected class from all options
@ -469,4 +631,4 @@ document.addEventListener("DOMContentLoaded", function () {
});
});
</script>
</script>

View File

@ -20,7 +20,7 @@ table.dataTable tbody td {
<p style="color: red;"><?= session()->getFlashdata('error') ?></p>
<?php endif; ?>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th>S.No.</th>

View File

@ -276,7 +276,7 @@
<input type="file" id="Question_title_fileInput" style="display: none;">
<table id="attachment_table" class="table table-sm mb-0" style="margin-top: 30px;">
<table data-custom-table-css="table" id="attachment_table" class="table table-sm mb-0" style="margin-top: 30px;">
<thead>
<tr>
<th>Attachments</th>
@ -446,7 +446,7 @@
<input type="file" id="Question_title_fileInput" style="display: none;">
<table id="attachment_table_ecard" class="table table-sm mb-0" style="margin-top: 30px;">
<table data-custom-table-css="table" id="attachment_table_ecard" class="table table-sm mb-0" style="margin-top: 30px;">
<thead>
<tr>
<th>Attachments</th>
@ -1494,7 +1494,7 @@ template_name = '';
newRow.innerHTML = `
<td> ${item.file_name} </td>
<td> <a class="fa fa-trash" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
<td> <a class="mdi mdi-delete" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
`;
container.appendChild(newRow);

View File

@ -271,7 +271,7 @@
<input type="file" id="Question_title_fileInput" style="display: none;">
<table id="attachment_table" class="table table-sm mb-0" style="margin-top: 30px;">
<table data-custom-table-css="table" id="attachment_table" class="table table-sm mb-0" style="margin-top: 30px;">
<thead>
<tr>
<th>Attachments</th>
@ -450,7 +450,7 @@
<input type="file" id="Question_title_fileInput" style="display: none;">
<table id="attachment_table_ecard" class="table table-sm mb-0" style="margin-top: 30px;">
<table data-custom-table-css="table" id="attachment_table_ecard" class="table table-sm mb-0" style="margin-top: 30px;">
<thead>
<tr>
<th>Attachments</th>
@ -860,7 +860,7 @@
newRow.innerHTML = `
<td> ${item.file_name} </td>
<td> <a class="fa fa-trash" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
<td> <a class="mdi mdi-delete" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
`;
container.appendChild(newRow);
@ -1155,7 +1155,7 @@
newRow.innerHTML = `
<td> ${item.file_name} </td>
<td> <a class="fa fa-trash" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
<td> <a class="mdi mdi-delete" data-id="${item.id}" onclick="removeAttachment('${item.id}')"></a></td>
`;
container.appendChild(newRow);

View File

@ -229,6 +229,7 @@
});
var policy_type_id = "";
var other_auto_save_enable = false;
$('body').on('click', '.btnPolicyMaster', function() {
$("#append_html_for_other_policy_terms").empty();
@ -276,10 +277,12 @@
if (res.emp_count_by_policy != 0) {
$("#btnOtherTermsSubmit").hide();
$("#otherButtonSpecialCondition").hide();
other_auto_save_enable = false;
} else {
$("#btnOtherTermsSubmit").show();
$("#otherButtonSpecialCondition").show();
startAutoSubmit('OTHERS');
// startAutoSubmit('OTHERS');
other_auto_save_enable = true;
}
@ -760,12 +763,12 @@
}
function beautifyString(str) {
return str
.split('_') // Split the string by underscores
.map(word =>
word.charAt(0).toUpperCase() + word.slice(1).toLowerCase() // Capitalize each word
)
.join(' '); // Join with spaces instead of underscores
return str
.split('_') // Split the string by underscores
.map(word =>
word.charAt(0).toUpperCase() + word.slice(1).toLowerCase() // Capitalize each word
)
.join(' '); // Join with spaces instead of underscores
}
function autoSaveOtherTerms(){
@ -836,4 +839,42 @@
}
function debounceothers(fn, delay) {
let timeout;
return function () {
clearTimeout(timeout);
timeout = setTimeout(fn, delay);
};
}
$(document).ready(function () {
const form = document.querySelector("#otherPolicyTerms");
// MutationObserver (always runs)
const observer = new MutationObserver(() => {
$("#otherPolicyTerms").find("input, select, textarea").each(function () {
if (other_auto_save_enable) { // only bind autosave if enabled
if (!$(this).attr("data-observed")) {
const debouncedSave = debounceothers(autoSaveOtherTerms, 1000);
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
}
}
});
});
observer.observe(form, { childList: true, subtree: true });
// Bind for existing fields (only if enabled)
if (other_auto_save_enable) {
const debouncedSave = debounceothers(autoSaveOtherTerms, 1000);
$("#otherPolicyTerms").find("input, select, textarea").each(function () {
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
});
} else {
console.log("This policy has employee processed (autosave disabled) -- OTHERS") ;
}
});
</script>

View File

@ -167,7 +167,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S.No</th>

View File

@ -6,7 +6,7 @@
<div class="table-responsive" id="branch_table" >
<table class="table table-borderless table-nowrap mb-0" id="table-policies">
<table data-custom-table-css="table" class="table table-borderless table-nowrap mb-0" id="table-policies">
<thead class="thead-light">
<tr>
<th>Insurer</th>

View File

@ -155,7 +155,7 @@
<div class="col-md-8" style="margin-bottom:10px">
<table>
<table data-custom-table-css="table">
<tbody>
<tr>
<td style="width: 11%;"><span style="margin-right:20px;color:black;">Self:</span></td>
@ -283,7 +283,7 @@
</div>
<div style="margin-top:10px">
<table>
<table data-custom-table-css="table">
<tbody>
<tr>
<td style="width: 22%;">
@ -861,8 +861,10 @@
<label for="totalSumInsured">Sum Insured enhancement</label>
</div>
<div class="col-md-6">
<input type="radio" name="suminsuredenhancement" class="suminsuredenhancement" value="1"> Yes
<input type="radio" name="suminsuredenhancement" class="suminsuredenhancement" value="1">
<label for="">Yes</label>
<input type="radio" name="suminsuredenhancement" class="suminsuredenhancement" value="0" style="margin-left:10px"> No
<label for="">No</label>
</div>
</div>
@ -887,6 +889,7 @@
<script>
var policy_grid_id = $('#client_id').val();
var grid_html = '';
var gmc_auto_save_enable = false;
$('.close').click(function() {
@ -1136,10 +1139,12 @@
if (response.emp_count_by_policy != 0) {
$('#btnGridSubmit1').hide();
$('#myButtonSpecialCondition').hide();
gmc_auto_save_enable = false;
} else {
$('#btnGridSubmit1').show();
$('#myButtonSpecialCondition').show();
startAutoSubmit('GMC');
// startAutoSubmit('GMC');
gmc_auto_save_enable = true;
}
let jsonObject = JSON.parse(response.data);
@ -1991,4 +1996,43 @@
}
function debounce(fn, delay) {
let timeout;
return function () {
clearTimeout(timeout);
timeout = setTimeout(fn, delay);
};
}
$(document).ready(function () {
const form = document.querySelector("#policyJsonForm");
// MutationObserver (always runs)
const observer = new MutationObserver(() => {
$("#policyJsonForm").find("input, select, textarea").each(function () {
if (gmc_auto_save_enable) { // only bind autosave if enabled
if (!$(this).attr("data-observed")) {
const debouncedSave = debounce(autoSaveGmcTerms, 1000);
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
}
}
});
});
observer.observe(form, { childList: true, subtree: true });
// Bind for existing fields (only if enabled)
if (gmc_auto_save_enable) {
const debouncedSave = debounce(autoSaveGmcTerms, 1000);
$("#policyJsonForm").find("input, select, textarea").each(function () {
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
});
} else {
console.log("This policy has employee processed (autosave disabled) -- GMC") ;
}
});
</script>

View File

@ -136,7 +136,7 @@
<label for=""></label>
</div>
<div class="col-md-6">
<table>
<table data-custom-table-css="table">
<tbody>
<tr>
<td></td>
@ -473,6 +473,7 @@
var policy_grid_id = $('#client_id').val();
var grid_html = '';
var gpa_auto_save_enable = false;
$("#policyGPATerms").submit(function(event) {
@ -603,10 +604,12 @@
if (res.emp_count_by_policy != 0) {
$("#btnGPATermsSubmit").hide();
$("#gpaButtonSpecialCondition").hide();
gpa_auto_save_enable = false;
} else {
$("#btnGPATermsSubmit").show();
$("#gpaButtonSpecialCondition").show();
startAutoSubmit('GPA');
gpa_auto_save_enable = true;
}
@ -720,7 +723,17 @@
// console.log('jsonObject value', jsonObject[key])
// console.log('jsonObject value type', typeof jsonObject[key])
let elements = document.getElementsByName(key);
let elements; // declare the element variable
if (key === "terrorism") {
let form = document.getElementById("policyGPATerms");
elements = form.querySelectorAll('[name="terrorism"]');
} else {
elements = document.getElementsByName(key);
}
// let elements = document.getElementsByName(key);
if (elements && elements.length > 0) {
let element = elements[0];
@ -1086,4 +1099,43 @@
});
}
function debouncegpa(fn, delay) {
let timeout;
return function () {
clearTimeout(timeout);
timeout = setTimeout(fn, delay);
};
}
$(document).ready(function () {
const form = document.querySelector("#policyGPATerms");
// MutationObserver (always runs)
const observer = new MutationObserver(() => {
$("#policyGPATerms").find("input, select, textarea").each(function () {
if (gpa_auto_save_enable) { // only bind autosave if enabled
if (!$(this).attr("data-observed")) {
const debouncedSave = debouncegpa(autoSaveGpaTerms, 1000);
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
}
}
});
});
observer.observe(form, { childList: true, subtree: true });
// Bind for existing fields (only if enabled)
if (gpa_auto_save_enable) {
const debouncedSave = debouncegpa(autoSaveGpaTerms, 1000);
$("#policyGPATerms").find("input, select, textarea").each(function () {
$(this).on("input change", debouncedSave);
$(this).attr("data-observed", "true");
});
} else {
console.log("This policy has employee processed (autosave disabled) -- GPA");
}
});
</script>

View File

@ -2917,7 +2917,7 @@ function createCheckboxes(obj, additional_relationship = [], unique_id = null, p
<div class="form-group col-md-12">
<label>Choose applicable family members</label>
<table style="border-collapse: collapse;">
<table data-custom-table-css="table" style="border-collapse: collapse;">
<tbody>`;

View File

@ -339,7 +339,7 @@ function generateTable(unique_id) {
}
}
var table = $('<table class="table table-striped compact-table" />');
var table = $('<table data-custom-table-css="table" class="table table-striped compact-table" />');
var uniqueRows = new Set();
var emptyCellCount = 0;

View File

@ -349,7 +349,7 @@
</div>
<div id="insurerTableContainer" style="overflow: auto;">
<table class="table table-bordered co_share_table" id="insurerTable">
<table data-custom-table-css="table" class="table table-bordered co_share_table" id="insurerTable">
<thead>
<tr>
<th>Premium Details</th>
@ -1691,7 +1691,7 @@ function addInsurerColumn() {
$('#insurerTable thead tr').append(`
<th>
Insurer ${insurerCount}
${insurerCount > 1 ? `<a class="text-danger fa fa-trash delete-insurer" data-count="${insurerCount}" style="margin-left: 135px;"></a>` : ''}
${insurerCount > 1 ? `<a class="text-danger mdi mdi-delete delete-insurer" data-count="${insurerCount}" style="margin-left: 135px;"></a>` : ''}
</th>
`);

View File

@ -305,7 +305,7 @@ custom-dropdown-menu {
</div>
</div>
<div>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th>Sno</th>

View File

@ -642,7 +642,7 @@
</div>
<div id="insurerTableContainer" style="overflow: auto;">
<table class="table table-bordered co_share_table" id="insurerTable">
<table data-custom-table-css="table" class="table table-bordered co_share_table" id="insurerTable">
<thead>
<tr>
<th>Premium Details</th>
@ -4047,7 +4047,7 @@ function addInsurerColumn() {
$('#insurerTable thead tr').append(`
<th>
Insurer ${insurerCount}
${insurerCount > 1 ? `<a data-count="${insurerCount}" class="text-danger fa fa-trash delete-insurer" style="margin-left: 135px;"></a>` : ''}
${insurerCount > 1 ? `<a data-count="${insurerCount}" class="text-danger mdi mdi-delete delete-insurer" style="margin-left: 135px;"></a>` : ''}
</th>
`);

View File

@ -274,7 +274,7 @@ table.dataTable tbody td {
</div>
</div>
<div>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th><div class="column-header">S.No.</div></th>
@ -1073,7 +1073,7 @@ function appendFileTableBody(data)
.attr('target', '_blank') // Open in a new tab
.attr('style', 'font-size:18px;')
.attr('data-id', item.id)
.addClass('fa fa-download')
.addClass('mdi mdi-download')
// Append the <a> tag inside the <td>
@ -1168,14 +1168,14 @@ function appendVehicleFileTableBody(data)
.attr('href', '<?= base_url('download-kyc-docs/') ?>' + item.file_name)
.attr('style', 'font-size:18px;')
.attr('data-id', item.id)
.addClass('fa fa-download')
.addClass('mdi mdi-download')
.text(' '); // Space after the icon
// Create the delete link
var deleteLink = $('<a>')
.attr('style', 'font-size:18px;')
.attr('data-id', item.id)
.addClass('fa fa-trash')
.addClass('mdi mdi-delete')
.text(' '); // Space after the icon
// Append the download and delete icons inside the same <td>

View File

@ -78,7 +78,7 @@
<a href="<?= base_url("master/policy/create"); ?>" type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" data-toggle="" data-placement="top" title="Add" data-trigger="hover">ADD</a>
</div>
</div> -->
<table class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
<table data-custom-table-css="table" class="table table-sm table-hover m-0 table-centered dt-responsive nowrap w-100" cellspacing="0"
id="tickets-table">
<thead class="bg-light">
<tr>

View File

@ -122,7 +122,7 @@
<ul id="suggestions"></ul>
</div>
</div>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="emptable">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="emptable">
<thead class="bg-light">
<tr>
<th class="small-width">SNO</th>
@ -159,7 +159,7 @@
</div>
<div class="modal-body">
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="oldrestable" style="display: none;">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="oldrestable" style="display: none;">
<thead class="bg-light">
<tr>
<th class="small-width">SNO</th>
@ -186,7 +186,7 @@
</table>
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="restable">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="restable">
<thead class="bg-light">
<tr>
<th class="small-width">SNO</th>
@ -225,7 +225,7 @@
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
</div>
<div class="modal-body">
<table class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="restable">
<table data-custom-table-css="table" class="table table-hover m-0 table-centered dt-responsive w-100" cellspacing="0" id="restable">
<thead class="bg-light">
<tr>

View File

@ -40,7 +40,7 @@ table.dataTable tbody td {
<strong>Total Unbilled Amount:</strong> <span id="total_unbilled">0.00</span> |
<strong>Total Policy Count:</strong> <span id="total_policy_count"><?= $policy_count ?></span>
</div>
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S. No</th>
@ -142,7 +142,7 @@ table.dataTable tbody td {
</div>
<div class="modal-body" id="modal_body">
<div class="table-responsive">
<table class="table table-hover mb-0">
<table data-custom-table-css="table" class="table table-hover mb-0">
<thead class="bg-light" id="table_head_data">
<tr>
<th>Statement No.</th>

View File

@ -32,7 +32,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>S. No</th>

View File

@ -32,7 +32,7 @@
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead>
<tr>
<?php

View File

@ -122,7 +122,7 @@ th:first-child, td:first-child {
<h4 style="position: relative;">Employees</h4>
</div>
</div>
<table class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<table data-custom-table-css="table" class="table table-striped mb-0 nowrap" cellspacing="0" id="tickets-table">
<thead class="bg-light">
<tr>
<th><input type="checkbox" id="selectAll" onclick="toggleAll(this)"></th>

View File

@ -7,63 +7,22 @@
width: 100%;
}
/* HEADER */
thead th {
background-color: #00999E;
color: #fff !important;
border-top: 0px solid #fff !important;
border-bottom: 0px solid #fff !important;
}
/* .table thead th {
vertical-align: bottom;
border-bottom: 2px solid #fff;
} */
/* Rounded header corners */
thead th:first-child {
border-top-left-radius: 15px !important;
border-bottom-left-radius: 15px !important;
}
thead th:last-child {
border-top-right-radius: 15px !important;
border-bottom-right-radius: 15px !important;
}
/* BODY ROWS */
tbody td {
background: #F5FFFF; /* apply bg to td not tr */
padding: 12px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
}
/* Add shadow + spacing row "card" effect */
tbody tr {
/* box-shadow: 0 2px 5px rgba(0,0,0,0.08); */
}
/* Rounded corners for first + last cell of each row */
tbody tr td:first-child {
border-top-left-radius: 15px !important;
border-bottom-left-radius: 15px !important;
}
tbody tr td:last-child {
border-top-right-radius: 15px !important;
border-bottom-right-radius: 15px !important;
}
/* Hover effect */
#scroll-horizontal-datatable tbody tr:hover td {
background-color: #e0e0e0;
}
/* Search input with icon */
.dataTables_filter {
position: absolute;
}
.dataTables_filter input {
padding-right: 30px;
background: url('https://cdn.jsdelivr.net/npm/@mdi/svg/svg/magnify.svg') no-repeat right 8px center;
@ -123,10 +82,6 @@ tbody tr td:last-child {
white-space: nowrap !important;
} */
.text-custom-black{
color: #000000 !important;
}
.text-custom-grey{
font-size: 0.85em;
color: #6c757d !important;
@ -212,7 +167,7 @@ table thead th {
.form-control {
background-color: #ECECEC !important;
border: 1px solid #ccc; /* optional */
color: #000; /* keep text readable */
/* color: #000; keep text readable */
}
.form-control:focus {
@ -229,12 +184,11 @@ table thead th {
/* Text inside */
.select2-container .select2-selection__rendered {
color: #000 !important;
line-height: 36px !important;
}
.select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
background-color: #ECECEC !important;
background-color: #00999E !important;
}
@ -247,12 +201,12 @@ table thead th {
<div class="card-body maincard">
<div class="row">
<div class="col-6" style="align-self: center;">
<p class="title-text app-font-family" style="position: relative;">Tickets </p>
<p class="title-text app-font-family font-color-black" style="position: relative;">Tickets </p>
</div>
</div>
<div>
<table id="scroll-horizontal-datatable" class="table w-100 nowrap text-custom-black text-custom app-font-family">
<thead>
<table id="scroll-horizontal-datatable" class="table w-100 nowrap text-custom-black text-custom app-font-family app-datatable">
<thead class="app-table-head">
<tr>
<th>Ticket ID</th>
<th class="app-text-left">Name</th>
@ -265,7 +219,7 @@ table thead th {
<th>Updated At</th>
</tr>
</thead>
<tbody>
<tbody class="app-table-body">
<?php if (isset($ticket_data)) { ?>
<?php foreach($ticket_data as $index => $row){ ?>
@ -293,15 +247,17 @@ table thead th {
<td class="app-text-left"><?php echo $row['assignee_name'] ? $row['assignee_name'] : '-'; ?></td>
<td class="app-text-left">
<?php if (!empty($row['created_at'])):
$cdt = new DateTime($row['created_at']);
echo $cdt->format('d/m/Y') . "<br><span class='time'> " . $cdt->format('h:i a') . "</span>";
$cd = date("j F Y", strtotime($row['created_at']));
$ct = date("h:i a", strtotime($row['created_at']));
echo $cd . "<br><span class='time'> " . $ct . "</span>";
endif;
?>
</td>
<td class="app-text-left">
<?php if (!empty($row['updated_at'])):
$udt = new DateTime($row['updated_at']);
echo $udt->format('d/m/Y') . "<br><span class='time'> " . $udt->format('h:i a') . "</span>";
$ud = date("j F Y", strtotime($row['updated_at']));
$ut = date("h:i a", strtotime($row['updated_at']));
echo $ud . "<br><span class='time'> " . $ut . "</span>";
endif;
?>
</td>
@ -338,7 +294,7 @@ table thead th {
<div class="form-row mt-3 w-100">
<div class="form-group col-md-6 app-font-family">
<label for="client_id">Client</label>
<select class="form-control app-field-grey" id="client_id" name="client_id">
<select class="form-control app-field-grey font-color-black" id="client_id" name="client_id">
<option value="">Select Client</option>
<?php if(isset($client_list)) { ?>
<?php foreach ($client_list as $c) { ?>
@ -357,7 +313,7 @@ table thead th {
</div>
<div class="form-group col-md-1" style="padding:32.5px 0 0 18px;">
<button type="button" class="btn-custom app-btn-primary app-font-family" style="padding: 0 10px !important; border-radius:13px;" onclick="getAutoFetchDetails()"><i class="mdi mdi-cached app-text-white" style="font-size:24px;"></i></button>
<button type="button" class="btn-custom app-btn-primary app-font-family" style="padding: 0 10px !important; border-radius:13px;" onclick="getAutoFetchDetails()"><i class="mdi mdi-cached " style="font-size:24px;"></i></button>
</div>
</div>
</div>
@ -394,9 +350,17 @@ table thead th {
<label for="ticket_type">Ticket Type<span class="text-danger">*</span></label>
<select class="form-control" id="ticket_type" name="ticket_type" required onchange="hideandshowpolicy()">
<option value="">Select Ticket Type</option>
<option value="Sales" selected >Sales</option>
<option value="Service">Service</option>
<!-- <option value="Sales" selected >Sales</option> -->
<!-- <option value="Service">Service</option> -->
<!-- <option value="0">+ Add New</option> -->
<?php if (!empty($ticket_type)): ?>
<?php foreach ($ticket_type as $t): ?>
<option value="<?= esc($t['name']) ?>"
<?= (strtolower($t['name']) === "sales") ? 'selected' : '' ?>>
<?= esc($t['name']) ?>
</option>
<?php endforeach; ?>
<?php endif; ?>
</select>
</div>
@ -463,7 +427,7 @@ table thead th {
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn app-btn-primary app-btn-border-radius mr-2 app-text-white" onclick="resetTicket()">Reset</button>
<button type="button" class="btn app-btn-primary app-btn-border-radius mr-2 " onclick="resetTicket()">Reset</button>
<button type="button" class="btn app-btn-secondary app-btn-border-radius" onclick="submitTicket()">Save</button>
</div>
</form>
@ -683,62 +647,66 @@ table thead th {
document.getElementById('policy_id').value = policyId || "";
}
function hideandshowpolicy() {
var select = document.getElementById('ticket_type').value;
var policyContainer = document.getElementById('policy_container');
// function hideandshowpolicy() {
// var select = document.getElementById('ticket_type').value;
// var policyContainer = document.getElementById('policy_container');
if (select === 'Service') {
policyContainer.style.display = "block"; // show
// if (select === 'Service') {
// policyContainer.style.display = "block"; // show
// } else {
// policyContainer.style.display = "none"; // hide
// document.getElementById('policy_no').value = "";
// document.getElementById('policy_id').value = "";
// }
// }
function hideandshowpolicy() {
var select = document.getElementById('ticket_type');
var value = select.value;
var policyContainer = document.getElementById('policy_container');
if (value === "0") {
let newType = prompt("Enter new ticket type:");
if (newType && newType.trim() !== "") {
var formData = new FormData(form);
$.ajax({
url: "<?= base_url('ticketType') ?>",
type: "POST",
data: formData,
processData: false,
contentType: false,
dataType: 'json',
success: function(response) {
if (response.status === "success") {
let option = new Option(newType, newType);
let addNewOption = select.querySelector('option[value="0"]');
select.insertBefore(option, addNewOption);
select.value = newType;
value = newType;
console.log(response.message);
} else { console.log(response.message); value = ""; }
},
error: function(xhr) { console.log("Error: " + xhr.statusText); value = ""; }
});
} else {
policyContainer.style.display = "none"; // hide
document.getElementById('policy_no').value = "";
document.getElementById('policy_id').value = "";
select.value = "";
value = "";
}
}
// function hideandshowpolicy() {
// var select = document.getElementById('ticket_type');
// var value = select.value;
// var policyContainer = document.getElementById('policy_container');
if (value === 'Service') {
policyContainer.style.display = "block";
} else {
policyContainer.style.display = "none";
document.getElementById('policy_no').value = "";
document.getElementById('policy_id').value = "";
}
// if (value === "0") {
// let newType = prompt("Enter new ticket type:");
// if (newType && newType.trim() !== "") {
// $.ajax({
// url: "<?= base_url('ticketType') ?>",
// type: "POST",
// data: { name: newType },
// dataType: 'json',
// success: function(response) {
// if (response.status === "success") {
// let option = new Option(newType, newType);
// let addNewOption = select.querySelector('option[value="0"]');
// select.insertBefore(option, addNewOption);
// select.value = newType;
// value = newType;
// console.log(response.message);
// } else { console.log(response.message); value = ""; }
// },
// error: function(xhr) { console.log("Error: " + xhr.statusText); value = ""; }
// });
// } else {
// select.value = "";
// value = "";
// }
// }
// if (value === 'Service') {
// policyContainer.style.display = "block";
// } else {
// policyContainer.style.display = "none";
// document.getElementById('policy_no').value = "";
// document.getElementById('policy_id').value = "";
// }
// }
}
</script>
<script>
@ -766,42 +734,41 @@ $(document).ready(function() {
hideandshowpolicy();
var ticketsTable = $('#scroll-horizontal-datatable');
$('#scroll-horizontal-datatable_filter').prepend('<i class="mdi mdi-magnify"></i>');
if (ticketsTable.length) {
ticketsTable.DataTable({
scrollX: true,
dom: "<'row'<'col-sm-6'f><'col-sm-6 text-right'B>>" +
"<'row'<'col-sm-12'tr>>" +
"<'row'<'col-sm-5'i><'col-sm-7'p>>",
dom: "<'row'<'col-sm-2'f><'col-sm-10 text-right'B>>" +
"<'row'<'col-sm-12'tr>>" +
"<'row'<'col-sm-5'i><'col-sm-7'p>>",
buttons: [
{
text: '<i class="mdi mdi-plus app-text-white" ></i><span class="app-text-white app-font-family btn-custom"> Create New Ticket </span>',
className: 'btn app-btn-primary app-btn-border-radius app-text-white mr-2',
text: '<i class="mdi mdi-plus" ></i><span class="app-font-family btn-custom"> Create New Ticket </span>',
className: 'btn app-btn-primary app-btn-border-radius mr-2',
action: function(e, dt, node, config) {
openTicket();
}
},
{
extend: 'collection',
text: '<span class="app-text-white app-font-family btn-custom"> Export </span><i class="mdi mdi-menu-down app-text-white"></i>',
className: 'btn app-btn-secondary app-btn-border-radius app-text-white',
text: '<span class="app-font-family btn-custom"> Export </span><i class="mdi mdi-menu-down"></i>',
className: 'btn app-btn-secondary app-btn-border-radius',
buttons: [
{
extend: 'csv',
text: '<i class="mdi mdi-file-delimited app-text-white" ></i><span class="app-text-white app-font-family btn-custom"> CSV </span>',
text: '<i class="mdi mdi-file-delimited " ></i><span class=" app-font-family btn-custom"> CSV </span>',
title: 'Tickets',
className: 'app-btn-primary app-text-white',
className: 'app-btn-primary ',
},
{
extend: 'excel',
text: '<i class="mdi mdi-file-excel app-text-white" ></i><span class="app-text-white app-font-family btn-custom"> EXCEL </span>',
text: '<i class="mdi mdi-file-excel " ></i><span class=" app-font-family btn-custom"> EXCEL </span>',
title: 'Tickets',
exportOptions: {
orthogonal: 'sort'
},
className: 'app-btn-primary app-text-white',
className: 'app-btn-primary ',
}
]
}
@ -816,7 +783,6 @@ $(document).ready(function() {
},
paging: true,
pageLength: 25,
ordering: false,
});
} else {

View File

@ -41,7 +41,7 @@
}
.conversation-card{
border-radius: 15px !important;
border-radius: 25px !important;
box-shadow: 0 2px 4px 0 #00000040;
}
@ -125,12 +125,12 @@ hr{
/* Text inside */
.select2-container .select2-selection__rendered {
color: #000 !important;
/* color: #000 !important; */
line-height: 36px !important;
}
.select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
background-color: #ECECEC !important;
background-color: #00999E !important;
}
</style>
@ -188,7 +188,7 @@ hr{
</div>
<div class="row mb-2">
<div class="col-4 app-subtitle app-text-grey app-font-family">Policy Number</div>
<div class="col-8 app-text text-end app-font-family" style="font-weight: 500 !important;">
<div class="col-8 app-text text-end app-font-family app-text-black" style="font-weight: 500 !important;">
<?= (!empty($master[0]['policy_no']) && strtolower($master[0]['policy_no']) !== 'null')
? '<u class="app-text-black">
<a href="javascript:void(0);"
@ -209,7 +209,20 @@ hr{
</div>
<div class="row mb-2">
<div class="col-4 app-subtitle app-text-grey app-font-family">Status</div>
<div class="col-8 app-text app-text-black text-end app-font-family" style="font-weight: 500 !important;"><?= $master[0]['status'];?></div>
<div class="col-8 app-text app-text-black text-end app-font-family" style="font-weight: 500 !important;">
<?= (!empty($master[0]['status']) && strtolower($master[0]['status']) !== 'null')
? '<u class="app-text-black">
<a href="javascript:void(0);"
class="app-text-black"
onclick="statusHistory('.$master[0]['thz_id'].')"
data-toggle="modal"
data-target="#StatusModal"
title="Click to view Status History">'
.$master[0]['status'].'
</a>
</u>'
: 'N/A'; ?>
</div>
</div>
<div class="row mb-2">
<div class="col-4 app-subtitle app-text-grey app-font-family">Ticket Type</div>
@ -251,7 +264,7 @@ hr{
<!-- Conversation Card -->
<div class="card mb-3 conversation-card">
<div class="card-header d-flex justify-content-between align-items-center" style="background:none; border:none; padding-bottom: 0px;">
<p class="sub-title-text app-font-family" >Conversation</p>
<p class="sub-title-text app-font-family app-text-black" >Conversation</p>
</div>
<div class="card-body recard-scroll" style="padding:0 27px !important; margin:0 !important; background:#F5FFFF;">
<?php if(!empty($notes)): ?>
@ -283,7 +296,7 @@ hr{
<?php else: ?>
<div class="d-flex justify-content-center align-items-center app-font-family"
style="height: 45vh; width:100%;">
<p class="text-center app-font-family"><i>No Data Found</i></p>
<p class="text-center app-font-family font-color-black"><i>No Data Found</i></p>
</div>
<?php endif; ?>
</div>
@ -334,8 +347,15 @@ hr{
<label for="ticket_type" class="sub-title-text app-font-family">Ticket Type<span class="text-danger">*</span></label>
<select class="form-control" id="ticket_type" name="ticket_type" required>
<option value="">Select Ticket Type</option>
<option value="Sales">Sales</option>
<option value="Service">Service</option>
<!-- <option value="Sales">Sales</option>
<option value="Service">Service</option> -->
<?php if (!empty($ticket_type)): ?>
<?php foreach ($ticket_type as $t): ?>
<option value="<?= esc($t['name']) ?>" >
<?= esc($t['name']) ?>
</option>
<?php endforeach; ?>
<?php endif; ?>
</select>
</div>
@ -392,15 +412,17 @@ hr{
<?php if(!empty($related_tickets)): foreach($related_tickets as $j => $rt): ?>
<div class="card related-ticket-card app-font-family app-text"
style="cursor: pointer;"
onclick="window.location='<?= base_url().'/ticketConversationList?return_type=web&thz_id='.$rt['thz_id']; ?>'">
onclick="window.open('<?= base_url().'/ticketConversationList?return_type=web&thz_id='.$rt['thz_id']; ?>', '_blank')">
<div class="card-body">
<div class="d-flex justify-content-between align-items-center" style="margin-bottom: 10px !important;">
<h5 class="app-font-family app-text"><?php echo '# '.$rt['thz_id']." / ".$rt['ticket_type']; ?></h5>
<small classs="app-font-family" style="font-size:7px;">
<?php if (!empty($rt['created_at'])):
$cdt = new DateTime($rt['created_at']);
echo $cdt->format('d/m/Y') . "<span class='time'> " . $cdt->format('h:i a') . "</span>";
endif; ?>
$cd = date("j F Y", strtotime($rt['created_at']));
$ct = date("h:i a", strtotime($rt['created_at']));
echo $cd . " " . $ct;
endif;
?>
</small>
</div>
<p class="mt-1 app-font-family"
@ -414,7 +436,7 @@ hr{
else: ?>
<div class="d-flex justify-content-center align-items-center"
style="height: 50vh; width:100%;">
<p class="text-center"><i>No Data Found</i></p>
<p class="text-center font-color-black" ><i>No Data Found</i></p>
</div>
<?php endif; ?>
</div>
@ -438,7 +460,7 @@ hr{
else: ?>
<div class="d-flex justify-content-center align-items-center"
style="height: 50vh; width:100%;">
<p class="text-center"><i>No Data Found</i></p>
<p class="text-center font-color-black"><i>No Data Found</i></p>
</div>
<?php endif; ?>
</div>
@ -447,6 +469,23 @@ hr{
</div>
</div>
<div class="modal fade app-font-family" id="StatusModal" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered modal-lg" >
<!-- style="max-width: 775px !important;"> -->
<div class="modal-content" style="border-radius:15px;">
<div class="modal-header" style="border-bottom-width:0;">
<h4 class="modal-title title-text app-font-family">Status History</h4>
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
</div>
<div class="modal-body card-scroll history-container" style="padding:5px 11px 11px 11px!important;">
</div>
</div>
</div>
</div>
<script>
@ -566,4 +605,87 @@ hr{
}
});
}
</script>
<script>
function statusHistory(thzId) {
console.log("*****");
$.ajax({
url: "<?= base_url('ticketHistoryList?thz_id=') ?>" + thzId,
type: "GET",
dataType: "json",
success: function(response) {
let container = $(".history-container");
container.empty(); // clear old content
if (response.status === "success" && response.data.length > 0) {
let table = `
<div class="table-responsive">
<table data-custom-table-css="table" class="table w-100 nowrap text-custom-black text-custom app-font-family app-datatable">
<thead class="app-table-head">
<tr>
<th class="app-text app-text-white">S.No</th>
<th class="app-text app-text-white">Old Status</th>
<th class="app-text app-text-white">New Status</th>
<th class="app-text app-text-white">Updated By</th>
<th class="app-text app-text-white">Date/Time</th>
</tr>
</thead>
<tbody class="app-table-body">
`;
response.data.forEach((row, index) => {
table += `
<tr>
<td class="app-text" style="text-align:left; vertical-align:middle;">${index + 1}</td>
<td class="app-text" style="text-align:left; vertical-align:middle;">${row.old_value ?? '-'}</td>
<td class="app-text" style="text-align:left; vertical-align:middle;">${row.new_value ?? '-'}</td>
<td class="app-text" style="text-align:left; vertical-align:middle;">${row.created_name ?? '-'}</td>
<td class="app-text" style="text-align:left; vertical-align:middle;">${row.created_at
? (() => {
let dt = new Date(row.created_at);
let dateStr = dt.toLocaleDateString('en-GB', {
day: '2-digit',
month: 'long',
year: 'numeric'
});
let timeStr = dt.toLocaleTimeString('en-US', {
hour: '2-digit',
minute: '2-digit',
hour12: true
}).toLowerCase();
return `${dateStr} ${timeStr}`;
})()
: '-'
}</td>
</tr>
`;
});
table += `</tbody></table></div>`;
container.html(table);
} else {
container.html(`
<div class="d-flex justify-content-center align-items-center" style="height: 50vh; width:100%;">
<p class="text-center app-font-family font-color-black"><i>${response.message ?? 'No history found'}</i></p>
</div>
`);
}
$("#StatusModal").modal("show");
},
error: function(xhr) {
$(".history-container").html(`
<div class="d-flex justify-content-center align-items-center" style="height: 50vh; width:100%;">
<p class="text-center app-font-family font-color-black"><i>No Data Found</i></p>
</div>
`);
$("#StatusModal").modal("show");
// toastr.error("Something went wrong!", "Error");
console.error(xhr.responseText);
}
});
}
</script>

View File

@ -13,7 +13,7 @@
<div class="row">
<div class="col-12">
<div class="card-body">
<form role="form" class="parsley-examples" method="post" id="ticket_auto_query"
<form role="form" class="parsley-examples" style="color:black;" method="post" id="ticket_auto_query"
enctype="multipart/form-data">
<div class="form-group">
<div class="form-row">

View File

@ -2,6 +2,11 @@
.bg-staff {
background-color: #FFF5E5;
}
.label-font-size{
font-size:0.875rem;
}
</style>
<div class="row">
<div class="col-12">
@ -22,49 +27,49 @@
<!-- Navigation Tabs -->
<ul class="nav nav-pills navtab-bg">
<li class="nav-item">
<a href="#general-tab" data-toggle="tab" class="nav-link px-2 py-1 active" id="general_tab"
<a href="#general-tab" data-toggle="tab" class="nav-link px-2 py-1 active label-font-size" id="general_tab"
aria-expanded="true">
<i class="mdi mdi-ticket-account"></i>
<span class="d-none d-sm-inline-block">General</span>
<span class="d-none d-sm-inline-block ">General</span>
</a>
</li>
<li class="nav-item">
<a href="#reply-tab" data-toggle="tab" class="nav-link px-2 py-1" id="reply_tab"
<a href="#reply-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="reply_tab"
aria-expanded="false">
<i class="mdi mdi-message-processing"></i>
<span class="d-none d-sm-inline-block">Reply</span>
</a>
</li>
<li class="nav-item">
<a href="#note-tab" data-toggle="tab" class="nav-link px-2 py-1" id="note_tab"
<a href="#note-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="note_tab"
aria-expanded="false">
<i class="mdi mdi-note-text"></i>
<span class="d-none d-sm-inline-block">Notes</span>
</a>
</li>
<li class="nav-item">
<a href="#history-tab" data-toggle="tab" class="nav-link px-2 py-1" id="history_tab"
<a href="#history-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="history_tab"
aria-expanded="false">
<i class="mdi mdi-history"></i>
<span class="d-none d-sm-inline-block">History</span>
</a>
</li>
<li class="nav-item">
<a href="#autoQuery-tab" data-toggle="tab" class="nav-link px-2 py-1" id="auto_query_tab"
<a href="#autoQuery-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="auto_query_tab"
aria-expanded="false">
<i class="mdi mdi-robot mr-1"></i>
<span class="d-none d-sm-inline-block">Auto Query Content</span>
</a>
</li>
<li class="nav-item">
<a href="#uploads-tab" data-toggle="tab" class="nav-link px-2 py-1" id="uploads_tab"
<a href="#uploads-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="uploads_tab"
aria-expanded="false">
<i class="mdi mdi-file mr-1"></i>
<span class="d-none d-sm-inline-block">Claim Files</span>
</a>
</li>
<li class="nav-item">
<a href="#viewpolicyterms-tab" data-toggle="tab" class="nav-link px-2 py-1" id="viewpolicyterms_tab"
<a href="#viewpolicyterms-tab" data-toggle="tab" class="nav-link px-2 py-1 label-font-size" id="viewpolicyterms_tab"
aria-expanded="false">
<i class="mdi mdi-eye mr-1"></i>
<span class="d-none d-sm-inline-block">View Policy Terms</span>

View File

@ -50,7 +50,7 @@ table.dataTable tbody td {
</div>
<div class="table-responsive">
<table id="scroll-horizontal-datatable" class="table w-100 nowrap">
<table data-custom-table-css="table" id="scroll-horizontal-datatable" class="table w-100 nowrap">
<thead class="bg-light">
<tr>
<th>Claim Number</th>

Some files were not shown because too many files have changed in this diff Show More