CHANGE_MAIL_POLICY_TERMS_STATEMENT_UPLOAD_DELETION_QUERY_USER_HELPDESK_AND_OTHER_AND_LIVE_ISSUE_CHANGES : RV

This commit is contained in:
VENKATESHWARAN 2024-12-17 10:20:10 +05:30
parent 885e396e00
commit 205598304c
13 changed files with 593 additions and 268 deletions

View File

@ -118,6 +118,8 @@ class ClientController extends AdminController
$this->leadsModel = new LeadsModel();
}
//--------------------------------------------------------------------------------------------------------
public function checkDuplicateTableFieldValue()
{
$table = $this->request->getPost('table');
@ -2176,6 +2178,7 @@ class ClientController extends AdminController
$data['preandpostnatal'] = "";
$data['babyday1cover'] = "";
}
$data['9monthwaitingperiodwaived'] = str_replace(',', '', $this->request->getPost("9monthwaitingperiodwaived"));
$data['coverfromthedateofjoining'] = str_replace(',', '', $this->request->getPost("coverfromthedateofjoining"));
$data['waiverof1,2,3&4thyearexclusions'] = $this->request->getPost("waiverof1,2,3&4thyearexclusions");
@ -3791,7 +3794,16 @@ class ClientController extends AdminController
}
public function sendextraparam()
{
{
// $batch_data = [
// 'client_id' => 17,
// 'client_policy_id' => 30,
// 'client_branch_id' => 18,
// ];
// $batch_data['insurer_or_tpa'] = 'insurer';
// $batch_data['insurer_or_tpa'] = 'tpa';
// dd($this->request);
// $employeeRestController = new EmployeeServiceController();
@ -3808,9 +3820,18 @@ class ClientController extends AdminController
// $emp_data = $this->employeePolicyModel->getEmployeePolicyForEcard(12);
// $ids = array_column($emp_data, 'id');
// $EmpDataServiceController->sendMailForDownloadingECard($ids);
// $EmpDataServiceController = new EmpDataServiceController();
// $EmpDataServiceController->importDeletionValidation(['file_id' => 304]); //for live
// $result = $this->employeePolicyModel->getDeletionEmployeeDataForExportExcel($batch_data);
// print_rr($result); die;
// $empServiceController = new EmployeeServiceController();
// $res = $empServiceController->employeesOnboardPreprocess(['file_id' => '741']);
// $PolicyTransactionController = new PolicyTransactionController();
// $res = $PolicyTransactionController->validateInsurerStatement(['file_id' => '36']);
}
// -------------------------------------------------------------------------------------------------------
@ -3832,4 +3853,27 @@ class ClientController extends AdminController
return $this->respond(['status' => false, 'code' => 404, 'message' => 'No data to update'], 200);
}
}
// -------------------------------------------------------------------------------------------------------
public function enrollmentAddonSIAmountDropdown($client_policy_id)
{
if(!empty($client_policy_id)){
$client_policy_details = $this->clientPolicyModel->where('id', $client_policy_id)->where('policy_status', 1)->where('is_active', 1)->first();
if(!empty($client_policy_details) && $client_policy_details['policy_type_id'] == 3 && $client_policy_details['is_addon'] == 3){
$base_policy_id = $client_policy_details['base_policy'] ?? 0;
if(!empty($base_policy_id)){
}
}
}
}
}

View File

@ -751,11 +751,15 @@ class EmpDataServiceController extends BaseController
public function generateExcelForDeletion($export_data)
{
{
// dd($export_data);
$ids = [];
$objects = $this->employeePolicyModel->getDeletionEmployeeDataForExportExcel($export_data);
// dd($objects);
$totals = 0;
foreach ($objects as $obj) {
$ids[] = $obj->endorsement_primarykey;
@ -2932,6 +2936,14 @@ class EmpDataServiceController extends BaseController
$batch_code = $file['batch_code'];
$user_id = $file['created_by'];
$ref_data = [
'client_id' => $client_id,
'client_policy_id' => $client_policy_id,
'client_branch_id' => $client_branch_id,
'insurer_or_tpa' => $file['insurer_or_tpa'],
'event_type' => $file['event_type'],
];
$file_name_with_path = WRITEPATH . "/uploads/import_excel/" . $file['file_name'];
@ -2963,72 +2975,8 @@ class EmpDataServiceController extends BaseController
}
}
$db = \Config\Database::connect();
$sql = "
SELECT DISTINCT
a.id as endorsement_primarykey,
a.group_key,
employee_polices.id as primaryKey,
employees.name AS emp_name,
employees.emp_code AS emp_code,
employees.dob AS emp_dob,
employees.gender AS emp_gender,
employees.relationship AS emp_relationship,
'Has Define' as emp_type,
employee_polices.basic_cover_si,
employee_polices.uhid as risk_id,
employee_polices.policy_end_date,
employee_polices.rata_premimum as premium,
deletiondata.empstatus,
deletiondata.changeevent,
deletiondata.dateofexit,
deletiondata.reasonforexit,
deletiondata.status,
DATEDIFF(employee_polices.policy_end_date, deletiondata.dateofexit) AS no_of_days,
ROUND((employee_polices.rata_premimum * DATEDIFF(employee_polices.policy_end_date, deletiondata.dateofexit)) / 365, 2) AS pro_rata_premium,
ROUND(((employee_polices.rata_premimum * DATEDIFF(employee_polices.policy_end_date, deletiondata.dateofexit)) / 365) * 0.18, 2) AS gst,
ROUND(((employee_polices.rata_premimum * DATEDIFF(employee_polices.policy_end_date, deletiondata.dateofexit)) / 365) + (((employee_polices.rata_premimum * DATEDIFF(employee_polices.policy_end_date, deletiondata.dateofexit)) / 365) * 0.18), 2) AS total
FROM
emp_endorsement a
LEFT JOIN
employees ON a.emp_code = employees.emp_code and a.pk = employees.id
LEFT JOIN
employee_polices ON employees.id = employee_polices.employee_id
LEFT JOIN(
select aa.emp_code, aa.new_value as 'empstatus', bb.new_value as 'changeevent', cc.new_value as 'dateofexit', dd.new_value as 'reasonforexit', ee.new_value as 'status' from
( SELECT a1.emp_code, a1.field_name, a1.new_value from emp_endorsement as a1 where a1.field_name = 'emp_status') aa
left join
( SELECT b1.emp_code, b1.field_name, b1.new_value from emp_endorsement as b1 where b1.field_name = 'change_event') bb on aa.emp_code = bb.emp_code
left join
( SELECT c1.emp_code, c1.field_name, c1.new_value from emp_endorsement as c1 where c1.field_name = 'date_of_exit') cc on aa.emp_code = cc.emp_code
left join
( SELECT d1.emp_code, d1.field_name, d1.new_value from emp_endorsement as d1 where d1.field_name = 'reason_for_exit') dd on aa.emp_code = dd.emp_code
left JOIN
( SELECT e1.emp_code, e1.field_name, e1.new_value from emp_endorsement as e1 where e1.field_name = 'status') ee on aa.emp_code = ee.emp_code
) as deletiondata on a.emp_code = deletiondata.emp_code
WHERE employee_polices.client_policy_id = '$client_policy_id'
AND employees.client_branch_id = '$client_branch_id'
AND a.actions = 'd'
AND employee_polices.is_active = 1
AND employee_polices.status = 'active'
AND employees.is_active = 1
AND employees.emp_status = 'active'
AND (a.endorsement_id IS NULL OR a.endorsement_id = '')
group by group_key
";
$query = $db->query($sql);
$endorsement_data = $query->getResultArray();
$objects = $this->employeePolicyModel->getDeletionEmployeeDataForExportExcel($ref_data, 1);
$endorsement_data = $objects;
// dd($endorsement_data);

View File

@ -1762,9 +1762,11 @@ class EmployeeController extends AdminController
public function update_emp_data()
{
$data = $this->request->getPost();
$data['dob'] = date('Y-m-d', strtotime($data['dob']));
// print_rr($data);
// $data['dob'] = date('Y-m-d', strtotime($data['dob']));
$data['dob'] = change_date_format($data['dob'], 'd/m/Y', 'Y-m-d');
// print_rr($data); die;
// Fetch current employee data
$employee_data = $this->employeeModel->where('id', $data['employee_primary_id'])->first();
@ -1973,5 +1975,50 @@ class EmployeeController extends AdminController
return redirect()->back()->with('error', 'Log file not found.');
}
public function exportToExceltpadata()
{
// Create a new Spreadsheet
$spreadsheet = new Spreadsheet();
$sheet = $spreadsheet->getActiveSheet();
// Header row
$headers = [
'TPA_NAME', 'SHORT_NAME', 'TPA_BRANCH_NAME', 'TPA_BRANCH_CODE',
'TPA_CONTACT_PERSON_NAME', 'TPA_CONTACT_PERSON_EMAIL', 'TPA_CONTACT_PERSON_MOBILE',
'TPA_CONTACT_PERSON_DESIGNATION', 'IS_DELETED'
];
$sheet->fromArray($headers, NULL, 'A1');
// Data rows
$data = [
["ICICI Lombard Health Care", "IL Health care", "Chennai", "997133", "Heena", "dharanisri@jubiliant.in", "9043955294", "General Manager", "YES"],
["ICICI Lombard Health Care", "IL Health care", "Chennai", "997133", "Mahammad shireen", "mahammad.shireen@icicilombard.com", "8655420732", "Claims head", "NO"],
["Medi Assist Insurance TPA Private Limited", "Medi Assist", "Chennai", "YA0000000348", "Ragavi", "dharanisri@jubiliant.in", "9043955294", "Senior Manager", "YES"],
["Medi Assist Insurance TPA Private Limited", "Medi Assist", "Chennai", "YA0000000348", "Vijayalakshmi", "vijayalakshmi.c@mediassist.in", "7795542162", "Senior Executive | Account Management", "NO"],
["Vidal Health Insurance TPA", "Vidal", "Chennai", "YA0000000349", "vijalakshmi", "vijayalakshmi.c@mediassist.in", "7795542162", "Senior Executive", "NO"],
["Vidal Health Insurance TPA", "Vidal", "Chennai", "YA0000000349", "M.Pushparaj", "pushparaj.moorthy@vidalhealth.com", "8939634456", "Executive", "NO"],
["Digit in-House", "Digit in-House", "Go Digit General Insurance Ltd", "1", "sathish", "sathish.n@vidalhealth.com", "7823913800", "Senior Executive", "NO"],
["Digit in-House", "Digit in-House", "Go Digit General Insurance Ltd", "1", "Mr. Pavan", "TK.Pavankumar@godigit.com", "8754490492", "Strategic Partnerships", "NO"],
["Aditya Birla Health Insurance Co. Limited", "ABHI", "Chennai", "O1", "sathish", "sathish.n@vidalhealth.com", "7823913800", "Senior Executive", "NO"],
["Aditya Birla Health Insurance Co. Limited", "ABHI", "Chennai", "O1", "Jhonson Kj", "jhonson.kj@adityabirlacapital.com", "9900729513", "Executive", "NO"],
["Aditya Birla Health Insurance Co. Limited", "ABHI", "Chennai", "01", "Jhonson Kj", "jhonson.kj@adityabirlacapital.com", "9900729513", "Executive", "NO"],
["R Care Health", "R Care", "Chennai", "01", "Jeevanadam", "Jeevanandam.Kumaran@relianceada.com", "8825982053", "Executive", "NO"],
["IFFCO-TOKIO GENERAL INSURANCE CO. LTD", "ITGI", "Chennai", "01", "Anjali", "Anjali.K@ext.iffcotokio.co.in", "6374270165", "Senior Executive", "NO"],
["Star Health and Allied Insurance", "STAR", "Chennai", "110000", "Mr. Vijay Baskar", "vijayabhaskar.m@starhealth.in", "9840905286", "Area Manager", "NO"],
];
$sheet->fromArray($data, NULL, 'A2');
// Save the file
$filename = 'TPA_Data.xlsx';
$writer = new Xlsx($spreadsheet);
// Set headers for download
header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');
header('Content-Disposition: attachment; filename="' . $filename . '"');
header('Cache-Control: max-age=0');
$writer->save('php://output');
exit;
}
}

View File

@ -1744,6 +1744,7 @@ class PolicyTransactionController extends BaseController
$source_data = $this->PTCOShareDetailsModel->getNonReconcileredPolicyTransactions(month:$month,year:$year,insurer_id:$file['insurer_id'],insurer_branch_id:$file['branch_id']);
// var_dump($source_data);die();
// Kint::dump($source_data);//die();
// check policy no,insurer and etc in DB for this month
// if all good return true, otherwise return false with messssage
@ -1752,34 +1753,37 @@ class PolicyTransactionController extends BaseController
$is_row_empty = check_row_is_empty_or_null($excel_row);
if(!$is_row_empty)
{
break;
}
$is_source_found = 0;
$policy_start_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[4]);//policy_start_date from excel
$policy_end_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[5]);//policy_end_date from excel
$policy_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[1]);//policy_end_date from excel
$client_name = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[3]);//clientname from excel
$endorsement_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[2]);//policy_end_date from excel
foreach ($source_data as $source_key => $source_row)
{
if( ($policy_no == $source_row['policy_no']) && $endorsement_no == $source_row['endorsement_no'] && change_date_format($policy_start_date,'d/m/Y','Y-m-d') == $source_row['policy_start_date'] && change_date_format($policy_end_date,'d/m/Y','Y-m-d') == $source_row['policy_end_date'] && $client_name == $source_row['client_name'])
$is_source_found = 0;
$policy_start_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[4]);//policy_start_date from excel
$policy_end_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[5]);//policy_end_date from excel
$policy_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[1]);//policy_end_date from excel
$client_name = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[3]);//clientname from excel
$endorsement_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[2]);//policy_end_date from excel
foreach ($source_data as $source_key => $source_row)
{
$is_source_found = 1;
unset($source_data[$source_key]);
continue 2;
$source_endorsement_no = $source_row['endorsement_no'] !== null ? $source_row['endorsement_no'] : "";
if( ($policy_no == $source_row['policy_no']) && $endorsement_no == $source_endorsement_no && change_date_format($policy_start_date,'d-m-Y','Y-m-d') == $source_row['policy_start_date'] && change_date_format($policy_end_date,'d-m-Y','Y-m-d') == $source_row['policy_end_date'] && $client_name == $source_row['client_name'])
{
$is_source_found = 1;
unset($source_data[$source_key]);
continue 2;
}
}
if($is_source_found == 0)
{
// echo $excel_key.'-'.$excel_row[1] . '- not found<br>';
$error_data['error_code'] = 1;//match not found
// $error_data['error_data'] = ($error_data['error_data'] ?? []);
$error_data['error_data'] = array_merge($error_data['error_data'],[$excel_row[0]]);//match not found
}
}
if($is_source_found == 0)
{
// echo $excel_key.'-'.$excel_row[1] . '- not found<br>';
$error_data['error_code'] = 1;//match not found
// $error_data['error_data'] = ($error_data['error_data'] ?? []);
$error_data['error_data'] = array_merge($error_data['error_data'],[$excel_row[0]]);//match not found
}
}
// dd($error_data);
if($error_data['error_code'])
{
$status = 'failed';
@ -1850,94 +1854,96 @@ class PolicyTransactionController extends BaseController
$is_row_empty = check_row_is_empty_or_null($excel_row);
if(!$is_row_empty)
{
break;
}
$is_source_found = 0;
$policy_start_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[4]);//policy_start_date from excel
$policy_end_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[5]);//policy_end_date from excel
$policy_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[1]);//policy_end_date from excel
$client_name = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[3]);//clientname from excel
$endorsement_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[2]);//policy_end_date from excel
foreach ($source_data as $source_key => $source_row)
{
// Kint::dump(change_date_format($excel_row[3],'d/m/Y','Y-m-d'));
if( ($policy_no == $source_row['policy_no']) && $endorsement_no == $source_row['endorsement_no'] && change_date_format($policy_start_date,'d/m/Y','Y-m-d') == $source_row['policy_start_date'] && change_date_format($policy_end_date,'d/m/Y','Y-m-d') == $source_row['policy_end_date'] && $client_name == $source_row['client_name'])
$is_source_found = 0;
$policy_start_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[4]);//policy_start_date from excel
$policy_end_date = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[5]);//policy_end_date from excel
$policy_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[1]);//policy_end_date from excel
$client_name = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[3]);//clientname from excel
$endorsement_no = preg_replace('/^\p{Z}+|\p{Z}+$/u', '', $excel_row[2]);//policy_end_date from excel
foreach ($source_data as $source_key => $source_row)
{
$is_source_found = 1;
//calculate percentage first
$total_amt = 0;
$actual_bp_per = trim($excel_row[9]);
$actual_bp_brokerage = trim($excel_row[12]);
$actual_bp_amt = trim($excel_row[6]);
if(($actual_bp_brokerage && $actual_bp_brokerage != 0 && $actual_bp_brokerage != ""))
// Kint::dump(change_date_format($excel_row[3],'d-m-Y','Y-m-d'));
$source_endorsement_no = $source_row['endorsement_no'] !== null ? $source_row['endorsement_no'] : "";
if( ($policy_no == $source_row['policy_no']) && $endorsement_no == $source_endorsement_no && change_date_format($policy_start_date,'d-m-Y','Y-m-d') == $source_row['policy_start_date'] && change_date_format($policy_end_date,'d-m-Y','Y-m-d') == $source_row['policy_end_date'] && $client_name == $source_row['client_name'])
{
$total_amt += $actual_bp_brokerage;
//percentage reverse calculation
if($actual_bp_per == 0 || $actual_bp_per == "")
$is_source_found = 1;
//calculate percentage first
$total_amt = 0;
$actual_bp_per = trim($excel_row[9]);
$actual_bp_brokerage = trim($excel_row[12]);
$actual_bp_amt = trim($excel_row[6]);
if(($actual_bp_brokerage && $actual_bp_brokerage != 0 && $actual_bp_brokerage != ""))
{
$actual_bp_per = round(($actual_bp_brokerage / $actual_bp_amt) * 100,2);
$total_amt += $actual_bp_brokerage;
//percentage reverse calculation
if($actual_bp_per == 0 || $actual_bp_per == "")
{
$actual_bp_per = round(($actual_bp_brokerage / $actual_bp_amt) * 100,2);
}
}
}
else
{
$actual_bp_brokerage = $actual_bp_amt * ($actual_bp_per / 100);
$total_amt += $actual_bp_brokerage;
}
$actual_tp_per = trim($excel_row[10]);
$actual_tp_brokerage = trim($excel_row[13]);
$actual_tp_amt = trim($excel_row[7]);
if($actual_tp_brokerage && $actual_tp_brokerage != 0 && $actual_tp_brokerage != "")
{
$total_amt += $actual_tp_brokerage;
//percentage reverse calculation
if($actual_tp_per == 0 || $actual_tp_per == "")
else
{
$actual_tp_per = ($actual_tp_brokerage / $actual_tp_amt) * 100;
$actual_bp_brokerage = $actual_bp_amt * ($actual_bp_per / 100);
$total_amt += $actual_bp_brokerage;
}
}
else
{
$actual_tp_brokerage = $actual_tp_amt * ($actual_tp_per / 100);
$total_amt += $actual_tp_brokerage;
}
$actual_tep_per = trim($excel_row[11]);
$actual_tep_brokerage = trim($excel_row[14]);
$actual_tep_amt = trim($excel_row[8]);
$actual_tp_per = trim($excel_row[10]);
$actual_tp_brokerage = trim($excel_row[13]);
$actual_tp_amt = trim($excel_row[7]);
if($actual_tep_brokerage && $actual_tep_brokerage != 0 && $actual_tep_brokerage != "")
{
$total_amt += $actual_tep_brokerage;
//percentage reverse calculation
if($actual_tep_per == 0 || $actual_tep_per == "")
if($actual_tp_brokerage && $actual_tp_brokerage != 0 && $actual_tp_brokerage != "")
{
$actual_tep_per = ($actual_tep_brokerage / $actual_tep_amt) * 100;
$total_amt += $actual_tp_brokerage;
//percentage reverse calculation
if($actual_tp_per == 0 || $actual_tp_per == "")
{
$actual_tp_per = ($actual_tp_brokerage / $actual_tp_amt) * 100;
}
}
else
{
$actual_tp_brokerage = $actual_tp_amt * ($actual_tp_per / 100);
$total_amt += $actual_tp_brokerage;
}
$actual_tep_per = trim($excel_row[11]);
$actual_tep_brokerage = trim($excel_row[14]);
$actual_tep_amt = trim($excel_row[8]);
if($actual_tep_brokerage && $actual_tep_brokerage != 0 && $actual_tep_brokerage != "")
{
$total_amt += $actual_tep_brokerage;
//percentage reverse calculation
if($actual_tep_per == 0 || $actual_tep_per == "")
{
$actual_tep_per = ($actual_tep_brokerage / $actual_tep_amt) * 100;
}
}
else
{
$actual_tep_brokerage = $actual_tep_amt * ($actual_tep_per / 100);
$total_amt += $actual_tep_brokerage;
}
//find variance
$variance_amt = $source_row['exp_amt'] - $total_amt;
$data_to_update[] = ['id' => $source_row['id'],'actual_bp_amt' => $actual_bp_amt,'actual_tp_amt' => $actual_tp_amt,'actual_tep_amt' => $actual_tep_amt,'actual_bp_per' => $actual_bp_per,'actual_tp_per' => $actual_tp_per,'actual_tep_per' => $actual_tep_per,'variance' => $variance_amt,'actual_tep_brokerage_amt' => $actual_tep_brokerage,'actual_tp_brokerage_amt' => $actual_tp_brokerage,'actual_bp_brokerage_amt' => $actual_bp_brokerage,'reward' => trim($excel_row[15]),'statement_id' => $file_id];
unset($source_data[$source_key]);
continue 2;
}
else
{
$actual_tep_brokerage = $actual_tep_amt * ($actual_tep_per / 100);
$total_amt += $actual_tep_brokerage;
}
//find variance
$variance_amt = $source_row['exp_amt'] - $total_amt;
$data_to_update[] = ['id' => $source_row['id'],'actual_bp_amt' => $actual_bp_amt,'actual_tp_amt' => $actual_tp_amt,'actual_tep_amt' => $actual_tep_amt,'actual_bp_per' => $actual_bp_per,'actual_tp_per' => $actual_tp_per,'actual_tep_per' => $actual_tep_per,'variance' => $variance_amt,'actual_tep_brokerage_amt' => $actual_tep_brokerage,'actual_tp_brokerage_amt' => $actual_tp_brokerage,'actual_bp_brokerage_amt' => $actual_bp_brokerage,'reward' => trim($excel_row[15]),'statement_id' => $file_id];
unset($source_data[$source_key]);
continue 2;
}
}
}
// dd($data_to_update);
$this->PTCOShareDetailsModel->updateBatch($data_to_update, 'id');
// dd($data_to_update);
// if($error_data['error_code'])

View File

@ -71,39 +71,43 @@ class UserController extends AdminController
$this->userTeamsModel->insert($teamData);
}
$db = \Config\Database::connect();
$tableName = 'hdz_staff';
// Set default values
$admin = 0;
$acm = 0;
$acm_id = null;
if ($userData['role'] == 3) {
$db = \Config\Database::connect();
$tableName = 'hdz_staff';
$admin = 0;
$acm = 1;
$acm_id = $insert;
$password = '12345678'; //Default password
$hashedPassword = password_hash($password, PASSWORD_DEFAULT);
foreach ($temp_team as $key => $value) {
$team = $this->teamModel->where('id', $value)->first();
if ($team['name'] == 'Claims') {
$hdz_staff = [
'emp_code' => $userData['emp_code'],
'fullname' => $userData['first_name'],
'username' => strtolower($userData['first_name']),
'email' => $userData['email'],
'admin' => $admin,
'acm' => $acm,
'acm_id' => $acm_id,
'registration' => time(),
'password' => $hashedPassword,
'active' => 1,
];
$db->table($tableName)->insert($hdz_staff);
}
}
} else if (in_array($userData['role'], [1, 5])) {
$admin = 1;
$acm = 0;
$acm_id = null;
}
$password = '12345678'; // Default password
$hashedPassword = password_hash($password, PASSWORD_DEFAULT);
$hdz_staff = [
'emp_code' => $userData['emp_code'],
'fullname' => $userData['first_name'],
'username' => strtolower($userData['first_name']),
'email' => $userData['email'],
'admin' => $admin,
'acm' => $acm,
'acm_id' => $acm_id,
'registration' => time(),
'password' => $hashedPassword,
'active' => 1,
'department' => 'a:7:{i:0;s:1:"1";i:1;s:1:"2";i:2;s:1:"5";i:3;s:1:"3";i:4;s:1:"9";i:5;s:1:"4";i:6;s:2:"10";}',
];
$db->table($tableName)->insert($hdz_staff);
}
}
$this->myLogger->logme('error', 'User create Successfully created by id {data}', ['data' => get_session_userid()]);
@ -149,33 +153,55 @@ class UserController extends AdminController
}
}
$db = \Config\Database::connect();
$tableName = 'hdz_staff';
$hdz_staff = [
'emp_code' => $userData['emp_code'],
'fullname' => $userData['first_name'],
'username' => strtolower($userData['first_name']),
'email' => $userData['email'],
'registration' => time(),
'active' => 1,
'department' => 'a:7:{i:0;s:1:"1";i:1;s:1:"2";i:2;s:1:"5";i:3;s:1:"3";i:4;s:1:"9";i:5;s:1:"4";i:6;s:2:"10";}',
];
if ($userData['role'] == 3) {
$db = \Config\Database::connect();
$tableName = 'hdz_staff';
$admin = 1;
foreach ($userData['team'] as $key => $value) {
if ($value == 2) {
$hdz_staff = [
'emp_code' => $userData['emp_code'],
'fullname' => $userData['first_name'],
'username' => strtolower($userData['first_name']),
'email' => $userData['email'],
'admin' => $admin,
'registration' => time(),
'active' => 1,
];
$db->table($tableName)->where('emp_code', $userData['emp_code'])
->where('email', $userData['email'])
->set($hdz_staff)
->update();
}
}
$hdz_staff['admin'] = 0;
$hdz_staff['acm'] = 1;
$hdz_staff['acm_id'] = $id;
} elseif (in_array($userData['role'], [1, 5])) {
$hdz_staff['admin'] = 1;
$hdz_staff['acm'] = 0;
$hdz_staff['acm_id'] = null;
} else {
return redirect()->to(base_url('/user/list'));
}
// Check if staff data exists
$staffData = $db->table($tableName)
// ->where('emp_code', $userData['emp_code'])
->where('email', $userData['email'])
->get()->getResult();
if (!empty($staffData)) {
// Update existing record
$db->table($tableName)
// ->where('emp_code', $userData['emp_code'])
->where('email', $userData['email'])
->set($hdz_staff)->update();
} else {
$password = '12345678'; // Default password
$hdz_staff['password'] = password_hash($password, PASSWORD_DEFAULT);
// Insert new record
$db->table($tableName)->insert($hdz_staff);
}
}
return redirect()->to(base_url('/user/list'));

View File

@ -203,6 +203,7 @@ class sendMailNotification
$temp_data = '';
$policy_name = '';
$is_addon = '';
$rowspan = count($item) ?? 2;
foreach ($item as $inner_item) {
@ -215,8 +216,10 @@ class sendMailNotification
}
//end of getting policy premium data
// dd($policy_premium_data);
if($inner_item['payable_employee'] == 1 && $client_policy_data['policy_type_id'] == 2){
$payable_employee_array[] = $inner_item;
$payable_employee_array['emp_data'][] = $inner_item;
}
// dd($policy_premium_data);
@ -235,7 +238,18 @@ class sendMailNotification
$gst_forself = '';
// if(checkFamilyFloaters($policy_premium_data, $client_policy_data, $inner_item)){
$si = '₹ ' .format_indian_number($inner_item['basic_cover_si']);
if($policy_premium_data['premium_type'] == 2){
$si = '₹ ' .format_indian_number($inner_item['basic_cover_si']);
}else{
if ($inner_item['relationship'] == 'Self') {
$payable_employee_array['si_amount'] = $inner_item['basic_cover_si'];
$payable_employee_array['self_premium'] = $inner_item['rata_premimum'];
$payable_employee_array['self_gst'] = $inner_item['gst'];
}
empty($inner_item['basic_cover_si']) ? $si = 0 : $si = '₹ ' .format_indian_number($inner_item['basic_cover_si']);
}
$premium = '₹ ' .format_indian_number(round($inner_item['rata_premimum']));
$gst_forself = '₹ ' .format_indian_number(round($inner_item['gst']));
// }
@ -244,8 +258,13 @@ class sendMailNotification
$temp_data .= '<td>' . $inner_item['name'] . ($inner_item['relationship'] == 'Self' ? ' (' . $inner_item['emp_code'] . ')' : '') . '</td>';
$temp_data .= '<td>' . $inner_item['relationship'] . '</td>';
$temp_data .= '<td>' . \DateTime::createFromFormat('Y-m-d', $inner_item['dob'])->format('d-m-Y') . '</td>';
$temp_data .= '<td>' . $si . '</td>';
if($policy_premium_data['premium_type'] == 2){
$temp_data .= '<td>' . $si . '</td>';
}else{
$temp_data .= (($si != 0 && count($item) != 1) ? ('<td rowspan='.$rowspan.'>' . $si . '</td>') : ($si == 0 ? "" : '<td>' . $si . '</td>') );
}
// Only Display SI Topup and Dependent Addon
if ($inner_item['is_addon'] == 2 || $inner_item['is_addon'] == 3) {
$temp_data .= '<td>' . $premium . '</td>';
@ -305,14 +324,24 @@ class sendMailNotification
$gst = 0;
}
if(count($payable_employee_array) > 0){
// dd($payable_employee_array);
// dd(count($payable_employee_array['emp_data']));
if(count($payable_employee_array['emp_data']) > 0){
$table_content .= '<div style="text-align: left; font-size: 12px;"><div style="text-align:left;"><h4>Policy Type :';
$temp_data = '';
$is_addon = '';
foreach ($payable_employee_array as $inner_item) {
$rowspan = count($payable_employee_array['emp_data']) ?? 2;
$self_si_amount = $payable_employee_array['si_amount'] ?? 0;
$self_premium = $payable_employee_array['self_premium'] ?? 0;
$self_gst = $payable_employee_array['self_gst'] ?? 0;
// dd($payable_employee_array['si_amount'], $self_si_amount);
foreach ($payable_employee_array['emp_data'] as $inner_item) {
//getting policy premium data
$client_policy_data = $clientPolicyModel->where('id', $inner_item['client_policy_id'])->first();
@ -323,22 +352,63 @@ class sendMailNotification
}
//end of getting policy premium data
// dd($policy_premium_data);
$si = '';
$premium = '';
$gst_forself = '';
$si = '₹ ' .format_indian_number($inner_item['basic_cover_si']);
$premium = '₹ ' .format_indian_number(round($inner_item['rata_premimum']));
$gst_forself = '₹ ' .format_indian_number(round($inner_item['gst']));
if($policy_premium_data['premium_type'] == 2){
$si = '₹ ' .format_indian_number($inner_item['basic_cover_si']);
}else{
empty($self_si_amount) ? $si = 0 : $si = '₹ ' .format_indian_number($self_si_amount);
}
if($policy_premium_data['premium_type'] == 1){
empty($self_premium) ? $premium = 0 : $premium = '₹ ' .format_indian_number($self_premium);
empty($self_gst) ? $gst_forself = 0 : $gst_forself = '₹ ' .format_indian_number($self_gst);
}else{
$premium = '₹ ' .format_indian_number(round($inner_item['rata_premimum']));
$gst_forself = '₹ ' .format_indian_number(round($inner_item['gst']));
}
$temp_data .= '<tr>';
$temp_data .= '<td>' . $inner_item['name'] . ($inner_item['relationship'] == 'Self' ? ' (' . $inner_item['emp_code'] . ')' : '') . '</td>';
$temp_data .= '<td>' . $inner_item['relationship'] . '</td>';
$temp_data .= '<td>' . \DateTime::createFromFormat('Y-m-d', $inner_item['dob'])->format('d-m-Y') . '</td>';
$temp_data .= '<td>' . $si . '</td>';
$temp_data .= '<td>' . $premium . '</td>';
$temp_data .= '<td>' . $gst_forself . '</td>';
// dd($si);
if($policy_premium_data['premium_type'] == 2){
$temp_data .= '<td>' . $si . '</td>';
$temp_data .= '<td>' . $premium . '</td>';
$temp_data .= '<td>' . $gst_forself . '</td>';
}else{
if($policy_premium_data['premium_type'] == 1){
$temp_data .= (($si != 0 && count($item) != 1) ? ('<td rowspan='.$rowspan.'>' . $si . '</td>') : ($si == 0 ? "" : '<td>' . $si . '</td>') );
$temp_data .= (($premium != 0 && count($item) != 1) ? ('<td rowspan='.$rowspan.'>' . $premium . '</td>') : ($premium == 0 ? "" : '<td>' . $premium . '</td>') );
$temp_data .= (($gst_forself != 0 && count($item) != 1) ? ('<td rowspan='.$rowspan.'>' . $gst_forself . '</td>') : ($gst_forself == 0 ? "" : '<td>' . $gst_forself . '</td>') );
}else{
$temp_data .= (($si != 0 && count($item) != 1) ? ('<td rowspan='.$rowspan.'>' . $si . '</td>') : ($si == 0 ? "" : '<td>' . $si . '</td>') );
$temp_data .= '<td>' . $premium . '</td>';
$temp_data .= '<td>' . $gst_forself . '</td>';
}
$self_si_amount = 0;
$self_premium = 0;
$self_gst = 0;
}
$temp_data .= '</tr>';

View File

@ -54,6 +54,39 @@ class ClientPolicyModel extends Model
"is_member_modify_allowed",
];
// Callbacks
protected $allowCallbacks = true;
protected $beforeInsert = ["checkAndADDCreatedByValue"];
protected $afterInsert = [];
protected $beforeUpdate = ["checkAndUpdateUpdatedByValue"];
protected $afterUpdate = [];
protected $beforeFind = [];
protected $afterFind = [];
protected $beforeDelete = [];
protected $afterDelete = [];
protected function checkAndADDCreatedByValue(array $data)
{
// Check if 'updated_by' value is null or empty
if (empty($data['data']['created_by'])) {
// Set 'updated_by' value to the current session user ID
$data['data']['created_by'] = get_session_userid();
}
return $data;
}
protected function checkAndUpdateUpdatedByValue(array $data)
{
// Check if 'updated_by' value is null or empty
if (empty($data['data']['updated_by'])) {
// Set 'updated_by' value to the current session user ID
$data['data']['updated_by'] = get_session_userid();
}
return $data;
}
public function getClientPolicyById($id){
return $this->db->table('client_policy')

View File

@ -557,7 +557,7 @@ class EmployeePolicyModel extends Model
}
public function getDeletionEmployeeDataForExportExcel($ref_data)
public function getDeletionEmployeeDataForExportExcel($ref_data, $return_type = 0)
{
$client_id = $ref_data['client_id'];
@ -618,8 +618,7 @@ class EmployeePolicyModel extends Model
employee_polices.basic_cover_si,
employee_polices.uhid as uhid,
employee_polices.policy_end_date,
employee_polices.premium,
employee_polices.rata_premimum as pro_rata_premium,
employee_polices.rata_premimum as premium,
employee_polices.claim_status,
batch_data.emp_policy_id AS emp_policy_id,
@ -714,9 +713,14 @@ class EmployeePolicyModel extends Model
group by group_key
");
$result = $query->getResult();
if($return_type == 1){
$result = $query->getResultArray();
}else{
$result = $query->getResult();
}
// dd($this->db->getLastQuery(), $result);
return $result;
}

View File

@ -257,7 +257,6 @@
}
})
var policy_PrimaryKey = $('#client_id_policy').val();
var policy_client = $('#policy_PrimaryKey').val();

View File

@ -217,7 +217,7 @@
<div class="form-group col-md-8">
<label for="name">Name<span class="text-danger">*</span></label>
<input type="text" class="form-control" id="name" placeholder="Ente Name" readonly>
<input type="text" class="form-control" name="name" id="name" placeholder="Ente Name">
</div>
</div>
<div class="form-row">
@ -264,7 +264,7 @@
$(document).ready(function(){
var dob = flatpickr("#dob", {
dateFormat: "d/m/Y",
dateFormat: "d/M/Y",
allowInput: false
});
})

View File

@ -332,7 +332,7 @@ table.dataTable tbody td {
<td><input type="number" class="form-control" name="received_amount[]" placeholder="Enter Amount" required onchange="checkInvAmont(event)"></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><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>
</tr>
</tbody>
@ -515,13 +515,13 @@ table.dataTable tbody td {
<td><input type="number" class="form-control" name="received_amount[]" placeholder="Enter Amount" onchange="checkInvAmont(event)" required></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" value="<?php echo date('d-m-Y'); ?>" name="payment_date[]" placeholder="Enter UTR No" required readonly></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>
`;
tableBody.appendChild(newRow);
$('.payment_date').datepicker({
format: 'dd-mm-yyyy',
format: 'dd/mm/yyyy',
autoclose: true
});
});
@ -579,15 +579,16 @@ function formatDate(date) {
var day = ("0" + date.getDate()).slice(-2);
var month = ("0" + (date.getMonth() + 1)).slice(-2);
var year = date.getFullYear();
return day + "-" + month + "-" + year;
return day + "/" + month + "/" + year;
}
function formatDateToDMY(dateStr) {
// Split the date string by the hyphen
var parts = dateStr.split('-');
return parts[2] + '-' + parts[1] + '-' + parts[0]; // Rearrange to DD-MM-YYYY
return parts[2] + '/' + parts[1] + '/' + parts[0]; // Rearrange to DD-MM-YYYY
}
function showInvoiceStatusModal(event)
{
console.log('############ showInvoiceStatusModal function called ##################');
var modal_received_amt_div = document.getElementById('modal_received_amt_div');
modal_received_amt_div.style.display = 'none';
// alert();
@ -635,7 +636,7 @@ function showInvoiceStatusModal(event)
// Clear existing rows in the payment table
var paymentTableBody = document.querySelector('#payment_table_modal tbody');
console.log('response.data.payments.length', response.data.payments.length)
// Populate payment table rows
if(response.data.payments.length)
{
@ -652,7 +653,7 @@ function showInvoiceStatusModal(event)
`;
});
}
$('.payment_date').datepicker({ format: 'dd-mm-yyyy',autoclose: true});
$('.payment_date').datepicker({ format: 'dd/mm/yyyy',autoclose: true});
// Show the modal
var myModal = new bootstrap.Modal(document.getElementById('invoice_modal'));
myModal.show();
@ -690,7 +691,7 @@ $(document).ready(function(){
$('.payment_date').datepicker({
format: 'dd-mm-yyyy',
format: 'dd/mm/yyyy',
autoclose: true
});
@ -705,7 +706,7 @@ minDate.setDate(today.getDate() - 180);
var maxDate = new Date();
maxDate.setDate(today.getDate() + 180);
$('#invoice_date_modal').datepicker({
format: 'dd-mm-yyyy',
format: 'dd/mm/yyyy',
autoclose: true,
startDate: minDate,
endDate: maxDate

View File

@ -39,6 +39,7 @@
.form-group-client-policy-masters {
display: -webkit-box;
max-width: 100% !important;
margin-left: -23px;
}
.flex-container {
@ -85,9 +86,9 @@
}
.s {
/* margin-left: 30px;
width: 689px; */
margin-left: 141px;
margin-left: 50px;
/* width: 689px; */
/* margin-left: 141px; */
width: 576px;
}
</style>
@ -221,6 +222,9 @@
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="waiverofpreexistingdiseases_display" id="waiverofpreexistingdiseases_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Waiver of Pre-existing Diseases</label>
</div>
@ -231,6 +235,9 @@
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="maternitycoverage_display" id="maternitycoverage_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Maternity Coverage</label>
</div>
@ -240,6 +247,9 @@
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="twindelivery_display" id="twindelivery_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Twin Delivery</label>
</div>
@ -249,6 +259,9 @@
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="preandpostnatal_display" id="preandpostnatal_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Pre and Post natal</label>
</div>
@ -258,6 +271,9 @@
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="babyday1cover_display" id="babyday1cover_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Baby Day 1 Cover</label>
</div>
@ -266,8 +282,10 @@
</div>
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="9monthwaitingperiodwaived_display" id="9monthwaitingperiodwaived_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">9-month waiting Period waived</label>
</div>
@ -278,6 +296,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="coverfromthedateofjoining_display" id="coverfromthedateofjoining_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Cover from the date of Joining</label>
</div>
@ -287,6 +308,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="waiverof1234thyearexclusions_display" id="waiverof1234thyearexclusions_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Waiver of 1, 2, 3 & 4th year Exclusions</label>
</div>
@ -298,6 +322,9 @@
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="waiverof30dayswaitingperiod_display" id="waiverof30dayswaitingperiod_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Waiver of 30 days waiting period</label>
</div>
@ -308,6 +335,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="prehospitalizationcover_display" id="prehospitalizationcover_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Pre Hospitalization Cover</label>
</div>
@ -317,6 +347,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="posthospitalizationcover_display" id="posthospitalizationcover_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Post Hospitalization Cover</label>
</div>
@ -326,6 +359,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="congenitaldiseasesinternal_display" id="congenitaldiseasesinternal_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Congenital Diseases - Internal</label>
</div>
@ -336,6 +372,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="congenitaldiseasesexternal_display" id="congenitaldiseasesexternal_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Congenital Diseases - External</label>
</div>
@ -345,6 +384,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="copayzonewisecopay_display" id="copayzonewisecopay_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Co-Pay/Zone wise Co Pay</label>
</div>
@ -354,7 +396,10 @@
</div>
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="co_pay_details_display" id="co_pay_details_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Co-pay Details</label>
</div>
@ -364,6 +409,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="bioabsorbablestenttoriclensmultifocallens_display" id="bioabsorbablestenttoriclensmultifocallens_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Bio absorbable stent / Toric lens/ Multi Focal lens</label>
</div>
@ -373,6 +421,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="roomrentlimit_display" id="roomrentlimit_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Room Rent Limit</label>
</div>
@ -382,6 +433,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="proportionatedeductionclause_display" id="proportionatedeductionclause_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Proportionate Deduction Clause</label>
</div>
@ -404,6 +458,9 @@
</div> -->
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="ailmentcapping_display" id="ailmentcapping_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Ailment capping</label>
</div>
@ -413,7 +470,10 @@
</div>
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="ailment_capping_details_display" id="ailment_capping_details_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Ailment capping Details</label>
</div>
@ -423,6 +483,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="corporatebuffer_display" id="corporatebuffer_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Corporate Buffer</label>
</div>
@ -432,6 +495,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="sublimitofcorporatebuffer_display" id="sublimitofcorporatebuffer_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Sublimit of Corporate Buffer</label>
</div>
@ -441,6 +507,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="ambulancecharges_display" id="ambulancecharges_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Ambulance Charges</label>
</div>
@ -450,6 +519,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="airambulance_display" id="airambulance_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Air Ambulance</label>
</div>
@ -459,6 +531,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="familytransportationbenefit_display" id="familytransportationbenefit_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Family Transportation Benefit</label>
</div>
@ -468,6 +543,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="reasonableandcustomarycharges_display" id="reasonableandcustomarycharges_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Reasonable and Customary Charges</label>
</div>
@ -478,6 +556,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="daycaretreatment_display" id="daycaretreatment_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Day Care Treatment</label>
</div>
@ -488,6 +569,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="ayudhtreatmentcover_display" id="ayudhtreatmentcover_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">AYUSH treatment cover</label>
</div>
@ -497,7 +581,10 @@
</div>
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="ayushTreatmentCoverData_display" id="ayushTreatmentCoverData_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">AYUSH treatment cover Limit</label>
</div>
@ -507,6 +594,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="armdcovered_display" id="armdcovered_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">ARMD Covered</label>
</div>
@ -516,6 +606,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="suminsuredenhancement_display" id="suminsuredenhancement_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Sum Insured enhancement</label>
</div>
@ -526,6 +619,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="automaticsuminsuredreinstatement_display" id="automaticsuminsuredreinstatement_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Automatic Sum Insured reinstatement</label>
</div>
@ -535,6 +631,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="additionalsicknessbenefit_display" id="additionalsicknessbenefit_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Additional Sickness Benefit</label>
</div>
@ -544,6 +643,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="lasiksurgery_display" id="lasiksurgery_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Lasik Surgery</label>
</div>
@ -553,6 +655,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="midterminclusion_display" id="midterminclusion_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Mid Term inclusion</label>
</div>
@ -562,6 +667,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="capd_display" id="capd_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">CAPD</label>
</div>
@ -571,6 +679,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="organdonorexpenses_display" id="organdonorexpenses_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Organ donor expenses</label>
</div>
@ -580,6 +691,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="moderntreatmentsasperirdai_display" id="moderntreatmentsasperirdai_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Modern treatments as per IRDAI</label>
</div>
@ -589,6 +703,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="Wellness_display" id="Wellness_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Wellness</label>
</div>
@ -598,6 +715,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="days_of_discharge_display" id="days_of_discharge_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Claim Intimation Clause</label>
</div>
@ -608,6 +728,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="days_from_dod_display" id="days_from_dod_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Claim Submission</label>
</div>
@ -618,6 +741,9 @@
</div>
<div class="row" style="margin-bottom: 10px;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="cataract_display" id="cataract_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Cataract</label>
</div>
@ -627,7 +753,10 @@
</div>
</div>
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="row" style="margin-bottom: 10px;display:none;">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="cataractData_display" id="cataractData_display" checked>
</div>
<div class="col-md-4">
<label for="totalSumInsured">Cataract Limit</label>
</div>
@ -1173,6 +1302,7 @@
});
}
$("#sum_insured").trigger("keyup");
$(".multiple_sum_insured").trigger("keyup");
@ -1350,6 +1480,9 @@
var index = $('.modifyclassinput').length;
var appendElement = `<div class="form-group col-md-6 form-group-client-policy-masters removeDom">
<div class="col-md-1">
<input type="checkbox" style="margin-top: 12px" name="special_condition_display_input[]" id="special_condition_display_input" checked>
</div>
<label for="specialconditionlabel" class="special_condition_label[]" style="width: 450px;position: relative;bottom: 6px;">
<input class="form-control" name="special_condition_label[]" id="special_condition_label[]" style="position: relative;right: 5px;">
<span class="specialConditionClose" style="color: red; float: right;position: relative;bottom: 28px;left: 15px;">X</span>

View File

@ -41,6 +41,10 @@ table.dataTable tbody td {
padding: 10px;
margin-bottom: 10px;
}
.addbtnStyle{
margin-left: 20px !important;
}
</style>
<style>
@ -240,7 +244,7 @@ table.dataTable tbody td {
</div>
<div class="col-3" id="status_change" style="text-align: right; position: relative;top: 56px; left: 291px;">
<button type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" onclick="hide_list_show_add();">Add</button>
<!-- <button type="button" id="btnAdd" class="btn btn-primary waves-effect waves-light" onclick="hide_list_show_add();">Add</button> -->
</div>
</div>
<div>
@ -420,17 +424,27 @@ $(document).ready(function() {
if (ticketsTable.length) {
ticketsTable.DataTable({
scrollX: true,
dom: "<'row'<'col-sm-6'f><'col-sm-5 text-right'B>>" + // Filter left, buttons right
dom: "<'row'<'col-sm-7'f><'col-sm-5 text-right'B>>" + // Filter left, buttons right
"<'row'<'col-sm-12'tr>>" +
"<'row'<'col-sm-5'i><'col-sm-7'p>>", // Pagination at the bottom, without page length selector
buttons: [{
extend: 'csv',
text: 'CSV',
title: 'Policy-Tranction-Inception-List',
exportOptions: {
columns: ':not(:last-child)'
},
}, ],
buttons: [
{
extend: 'csv',
text: 'CSV',
title: 'Policy-Tranction-Inception-List',
exportOptions: {
columns: ':not(:last-child)'
},
},
{
text: 'Add',
className: 'buttons-html5 addbtnStyle',
action: function (e, dt, node, config) {
hide_list_show_add();
}
}
],
language: {
search: "_INPUT_",
searchPlaceholder: "Search..."