From 0d8418259dbcfe9780f7a1565699fc8ba1dd9d1a Mon Sep 17 00:00:00 2001 From: velz Date: Wed, 8 Apr 2026 11:09:15 +0530 Subject: [PATCH] FIX_POLICY_TYPE_VALIDAION --- app/Controllers/LeadsController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Controllers/LeadsController.php b/app/Controllers/LeadsController.php index fd5ab968..9384b60d 100644 --- a/app/Controllers/LeadsController.php +++ b/app/Controllers/LeadsController.php @@ -506,7 +506,7 @@ class LeadsController extends BaseController 'errors' => ['required' => 'Claim Year is required for all entries.', 'regex_match' => 'Year must be in format YYYY-YYYY.'], ]; $rules['first_policy_type_.*'] = [ - 'rules' => 'required|regex_match[/^[a-zA-Z0-9_-]+$/]', + 'rules' => 'required|regex_match[/^[a-zA-Z0-9 _-]+$/]', 'errors' => ['required' => 'Policy Type is required in Claim History.', 'regex_match' => 'Policy Type only letters, numbers, space, hyphens and underscores are allowed', ], @@ -517,7 +517,7 @@ class LeadsController extends BaseController 'regex_match' => 'Date of Loss must be inValid format.'], ]; $rules['first_cause_of_loss.*'] = [ - 'rules' => 'required|regex_match[/^[a-zA-Z0-9\s_-]+$/]', + 'rules' => 'required|regex_match[/^[a-zA-Z0-9 _-]+$/]', 'errors' => [ 'required' => 'Cause of Loss is required.', 'regex_match' => 'Cause of Loss only letters, numbers, space, hyphens and underscores are allowed',