From db7697d13f83c7256c2fd34c7d79c356edf3cd67 Mon Sep 17 00:00:00 2001 From: Smart Date: Mon, 7 Oct 2024 08:56:18 +0530 Subject: [PATCH 1/4] CHANGE_added is_active condition for mobile no verification api : GWM --- app/Controllers/RestAuthenticationController.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/app/Controllers/RestAuthenticationController.php b/app/Controllers/RestAuthenticationController.php index b313789e..d4256270 100755 --- a/app/Controllers/RestAuthenticationController.php +++ b/app/Controllers/RestAuthenticationController.php @@ -71,7 +71,9 @@ class RestAuthenticationController extends AdminController $mobile_number = $this->request->getJSON()->mobile_number; - $employeeData = $this->employeeModel->where('mobile', $mobile_number)->where('relationship', 'self')->first(); + $employeeData = $this->employeeModel->where('mobile', $mobile_number) + ->where('relationship', 'self') + ->where('is_active', 1)->first(); if ($employeeData) { @@ -126,7 +128,9 @@ class RestAuthenticationController extends AdminController try { $mobile_number = $this->request->getJSON()->mobile_number; - $HrData = $this->hrModel->where('mobile', $mobile_number)->where('contact_type', 'client')->first(); + $HrData = $this->hrModel->where('mobile', $mobile_number) + ->where('contact_type', 'client') + ->where('is_active', 1)->first(); if ($HrData) { From 8ea9e82d828202ea857d7f06e8b46742a6b3f80a Mon Sep 17 00:00:00 2001 From: velz Date: Mon, 7 Oct 2024 10:05:23 +0530 Subject: [PATCH 2/4] FIX_REMOVED_ECHO --- app/Controllers/EmployeeServiceController.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/Controllers/EmployeeServiceController.php b/app/Controllers/EmployeeServiceController.php index 826c7e29..9f80c0a1 100755 --- a/app/Controllers/EmployeeServiceController.php +++ b/app/Controllers/EmployeeServiceController.php @@ -2045,13 +2045,13 @@ public function employeesEnrollmentInsert($params) //store email and mail content via helper to send notification $emp_emails[] = sendMailNotification::sendMailNotification('member_welcome_mail', $params); - Kint::dump($emp_emails); - Kint::dump($key.'-'.count($excel_data)); + // Kint::dump($emp_emails); + // Kint::dump($key.'-'.count($excel_data)); // if mail count is 20 send bulk mail and reset emp_emails variable if (count($emp_emails) == 20 || $key == count($excel_data) ) { $job_details = new Jobs(); $r = Jobs::addJob(['job_name' => 'bulk_mail','payload' => $emp_emails]); - echo 'Mail triggered'; + // echo 'Mail triggered'; $emp_emails = []; } @@ -2059,6 +2059,8 @@ public function employeesEnrollmentInsert($params) } } //end of for loop + + return true; } From a9ea4e2031e920a8fff2adac5e32dea74ede34a6 Mon Sep 17 00:00:00 2001 From: Smart Date: Mon, 7 Oct 2024 12:24:37 +0530 Subject: [PATCH 3/4] =?UTF-8?q?CHANGE=5Fin=20=1B[200~=20=20=20=20public=20?= =?UTF-8?q?function=20FloterNotesConvertion(){?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Controllers/EmployeeRestController.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/app/Controllers/EmployeeRestController.php b/app/Controllers/EmployeeRestController.php index e6aca562..79a02293 100755 --- a/app/Controllers/EmployeeRestController.php +++ b/app/Controllers/EmployeeRestController.php @@ -1463,15 +1463,13 @@ class EmployeeRestController extends AdminController $result = 'Can Add Self '; }else if($value != 0 && $key ==='childrens') { if($value > 1){ $result .= ' + '.$value.' Children'; }else{ $result .= ' + '.$value.' Child'; } + }else if($value != 0 && $key ==='parents'){ + if($value > 1){ $result .= ' + '.$value.' Parents'; }else{ $result .= ' + '.$value.' Parent'; } + }else if($value != 0 && $key ==='parents-in-law'){ + if($value > 1){ $result .= ' + '.$value.' Parent in law'; }else{ $result .= ' + '.$value.' Parents in law'; } }else if($value != 0 && $key ==='elders_count') { - }else{ - $string = str_replace('-', ' ', $key); - $string = ucwords($string); - $result .= ' + '.$value.' '.$string; } - - } } From 40fd8ba4ae302b17576e6bcd0dc8b5f0ea121291 Mon Sep 17 00:00:00 2001 From: Smart Date: Mon, 7 Oct 2024 12:29:14 +0530 Subject: [PATCH 4/4] CHANGE_in FloterNotesConvertion --- app/Controllers/EmployeeRestController.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/app/Controllers/EmployeeRestController.php b/app/Controllers/EmployeeRestController.php index 79a02293..aba83570 100755 --- a/app/Controllers/EmployeeRestController.php +++ b/app/Controllers/EmployeeRestController.php @@ -1453,7 +1453,7 @@ class EmployeeRestController extends AdminController if ($value > 0) { if($value == 1 && $key ==='either-parents-pil') { $result .= ' + Either 2 Parents or 2 Parents in law'; - }if($value == 2 && $key ==='either-parents-pil') { + }else if($value == 2 && $key ==='either-parents-pil') { $result .= ' + Any 2 of Parents and Parents in law'; }else if($value != 0 && $key ==='spouse') { $string = str_replace('-', ' ', $key); @@ -1463,13 +1463,15 @@ class EmployeeRestController extends AdminController $result = 'Can Add Self '; }else if($value != 0 && $key ==='childrens') { if($value > 1){ $result .= ' + '.$value.' Children'; }else{ $result .= ' + '.$value.' Child'; } - }else if($value != 0 && $key ==='parents'){ - if($value > 1){ $result .= ' + '.$value.' Parents'; }else{ $result .= ' + '.$value.' Parent'; } - }else if($value != 0 && $key ==='parents-in-law'){ - if($value > 1){ $result .= ' + '.$value.' Parent in law'; }else{ $result .= ' + '.$value.' Parents in law'; } }else if($value != 0 && $key ==='elders_count') { + }else{ + $string = str_replace('-', ' ', $key); + $string = ucwords($string); + $result .= ' + '.$value.' '.$string; } + + } }