From f4c4551dd892dffcb1c3df98c322c75a4ccad672 Mon Sep 17 00:00:00 2001 From: Gowtham M Date: Tue, 13 Jan 2026 18:49:33 +0530 Subject: [PATCH] GWM : iAgreeForAddOn policy handled --- app/Controllers/EmployeeRestController.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/app/Controllers/EmployeeRestController.php b/app/Controllers/EmployeeRestController.php index b2f844d..2d5a2a7 100755 --- a/app/Controllers/EmployeeRestController.php +++ b/app/Controllers/EmployeeRestController.php @@ -2715,8 +2715,12 @@ class EmployeeRestController extends AdminController $array_list = []; foreach ($client_policy_id as $key => $value) { - // $policy = $this->clientPolicyModel->where('id',$value)->where('open_for_enrollment',1)->find(); - $policy = $this->findThePolicyIsOpenForEnrollment($value, $emp_code); + + $clientPolicyData = $this->clientPolicyModel->where('client_id',$client_id) + ->where('id',$value) + ->where('is_active', 1) + ->first(); + $policy = $this->findThePolicyIsOpenForEnrollment($clientPolicyData['base_policy'], $emp_code); if($policy) { $this->myLogger->logme("error", 'client policy id = '.$value.' is open for enrollment');