Merge branch 'dev' of bitbucket.org:jubilian/nhance into dev

This commit is contained in:
VENKATESHWARAN 2026-01-29 17:50:59 +05:30
commit 9ec1413c8f
8 changed files with 49 additions and 27 deletions

View File

@ -1015,10 +1015,9 @@ class ClientController extends AdminController
] ]
], ],
'short_name' => [ 'short_name' => [
'rules' => 'required|alpha', 'rules' => 'required',
'errors' => [ 'errors' => [
'required' => 'Client Short Name is required', 'required' => 'Client Short Name is required',
'alpha' => 'Client Short Name can only contain alphabets.',
] ]
], ],
'pan' => [ 'pan' => [

View File

@ -437,7 +437,7 @@ class LeadsController extends BaseController
]; ];
$request_data = $this->request->getPost(); $request_data = $this->request->getPost();
$data = sanitizeInputArrayAdvanced($request_data); $data = sanitizeInputArrayAdvanced($request_data);
if($data['lead_form_type'] == 2){ if (isset($data['lead_form_type']) && (int)$data['lead_form_type'] === 2) {
$rules['client_type'] = [ $rules['client_type'] = [
'rules' => 'required', 'rules' => 'required',
'errors' => ['required' => 'Client Type is required'] 'errors' => ['required' => 'Client Type is required']

View File

@ -52,6 +52,7 @@ class NotificationController extends AdminController
// Create Or Update the Notification // Create Or Update the Notification
public function createNotification() public function createNotification()
{ {
$form_data['template_name'] = $this->camelCaseToSnakeCase($this->request->getPost('template_name')); $form_data['template_name'] = $this->camelCaseToSnakeCase($this->request->getPost('template_name'));
$form_data['subject'] = $this->request->getPost('subject'); $form_data['subject'] = $this->request->getPost('subject');
$form_data['mail_content'] = $this->request->getPost('mailContent'); $form_data['mail_content'] = $this->request->getPost('mailContent');

View File

@ -2156,10 +2156,9 @@
$('.btnDiv').show(); $('.btnDiv').show();
$('.claim-row').hide(); $('.claim-row').hide();
$('.emp_title_text').text('No of Employees')
$('.emp_title').text('No of Employees') $('.depnd_title_text').text('No of Dependents')
$('.depnd_title').text('No of Dependents') $('.total_title_text').text('Total Lives')
$('.total_title').text('Total Lives')
$('.renewalFields').find('select, input').removeAttr('required'); $('.renewalFields').find('select, input').removeAttr('required');
$('.renewalFields').hide(); $('.renewalFields').hide();
@ -2193,9 +2192,9 @@
$('.btnDiv').hide(); $('.btnDiv').hide();
$('.claim-row').show(); $('.claim-row').show();
$('.emp_title').text('No of Employees at Inception') $('.emp_title_text').text('No of Employees at Inception')
$('.depnd_title').text(' No of Dependents at Inception') $('.depnd_title_text').text(' No of Dependents at Inception')
$('.total_title').text('Total Lives at Inception') $('.total_title_text').text('Total Lives at Inception')
$('.freshFields').find('select, input').removeAttr('required'); $('.freshFields').find('select, input').removeAttr('required');
$('.freshFields').hide(); $('.freshFields').hide();

View File

@ -738,9 +738,9 @@
$('.claim-row').hide(); $('.claim-row').hide();
$('.emp_title').text('No of Employees') $('.emp_title_text').text('No of Employees')
$('.depnd_title').text('No of Dependents') $('.depnd_title_text').text('No of Dependents')
$('.total_title').text('Total Lives') $('.total_title_text').text('Total Lives')
$('.renewalFields').find('select, input').removeAttr('required'); $('.renewalFields').find('select, input').removeAttr('required');
$('.renewalFields').hide(); $('.renewalFields').hide();
@ -775,9 +775,9 @@
$('.btnDiv').hide(); $('.btnDiv').hide();
$('.claim-row').show(); $('.claim-row').show();
$('.emp_title').text('No of Employees at Inception') $('.emp_title_text').text('No of Employees at Inception')
$('.depnd_title').text(' No of Dependents at Inception') $('.depnd_title_text').text(' No of Dependents at Inception')
$('.total_title').text('Total Lives at Inception') $('.total_title_text').text('Total Lives at Inception')
$('.freshFields').find('select, input').removeAttr('required'); $('.freshFields').find('select, input').removeAttr('required');
$('.freshFields').hide(); $('.freshFields').hide();
@ -812,7 +812,6 @@
} }
} }
} }
var allContacts = ""; var allContacts = "";
function getBranchData(input,inputType) { function getBranchData(input,inputType) {

View File

@ -1524,7 +1524,7 @@
<form class="ajax" onsubmit="submitAttachmentForm(event, this)"> <form class="ajax" onsubmit="submitAttachmentForm(event, this)">
<div style="display:flex; align-items:center; gap:10px; white-space:nowrap;"> <div style="display:flex; align-items:center; gap:10px; white-space:nowrap;">
<div> <div>
<input type="file" name="file" required <input type="file" name="file"
style="width:100%; min-width:160px; style="width:100%; min-width:160px;
padding: 0 !important; padding: 0 !important;
background-color: transparent !important; background-color: transparent !important;
@ -1548,7 +1548,7 @@
newRow.innerHTML = `<td><form class="ajax" onsubmit="submitAttachmentForm(event, this)"> newRow.innerHTML = `<td><form class="ajax" onsubmit="submitAttachmentForm(event, this)">
<div style="display:flex; align-items:center; gap:10px; white-space:nowrap;"> <div style="display:flex; align-items:center; gap:10px; white-space:nowrap;">
<div> <div>
<input type="file" name="file" required <input type="file" name="file"
style="width:100%; min-width:160px; style="width:100%; min-width:160px;
padding: 0 !important; padding: 0 !important;
background-color: transparent !important; background-color: transparent !important;
@ -2009,6 +2009,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#account_maneger_summary_mail_modal').find('.close').click(); $('#account_maneger_summary_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2069,6 +2071,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#member_welcome_mail_modal').find('.close').click(); $('#member_welcome_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2129,6 +2133,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#member_reminder_mail_modal').find('.close').click(); $('#member_reminder_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2189,6 +2195,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#member_ecard_mail_modal').find('.close').click(); $('#member_ecard_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2248,6 +2256,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#member_common_mail_modal').find('.close').click(); $('#member_common_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2308,6 +2318,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#member_review_and_summary_mail_modal').find('.close').click(); $('#member_review_and_summary_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');
@ -2368,6 +2380,8 @@
type: "POST", type: "POST",
data: formData, data: formData,
dataType: 'json', dataType: 'json',
processData: false,
contentType: false,
success: function(res) { success: function(res) {
$('#client_hr_summary_mail_modal').find('.close').click(); $('#client_hr_summary_mail_modal').find('.close').click();
toastr.success('Template saved successfully'); toastr.success('Template saved successfully');

View File

@ -131,22 +131,28 @@
<div class="form-row"> <div class="form-row">
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="incept_emp_count" class="emp_title"> No of Employees at Inception <span <label for="incept_emp_count" class="emp_title">
class="text-danger"></span></label> <span class="emp_title_text"> No of Employees at Inception </span>
<span class="text-danger">*</span>
</label>
<input value="<?= isset($lead_edit_data['incept_emp_count']) ? $lead_edit_data['incept_emp_count'] : '' ?>" type="text" class="form-control" id="incept_emp_count" name="incept_emp_count[]" <input value="<?= isset($lead_edit_data['incept_emp_count']) ? $lead_edit_data['incept_emp_count'] : '' ?>" type="text" class="form-control" id="incept_emp_count" name="incept_emp_count[]"
placeholder="Enter Lives" required oninput="calculateTotalLives(this)"> placeholder="Enter Lives" required oninput="calculateTotalLives(this)">
</div> </div>
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="incept_dept_count" class="depnd_title"> No of Dependents at Inception <span <label for="incept_dept_count" class="depnd_title">
class="text-danger"></span></label> <span class="depnd_title_text"> No of Dependents at Inception </span>
<span class="text-danger">*</span>
</label>
<input value="<?= isset($lead_edit_data['incept_dept_count']) ? $lead_edit_data['incept_dept_count'] : '' ?>" type="text" class="form-control" id="incept_dept_count" name="incept_dept_count[]" <input value="<?= isset($lead_edit_data['incept_dept_count']) ? $lead_edit_data['incept_dept_count'] : '' ?>" type="text" class="form-control" id="incept_dept_count" name="incept_dept_count[]"
placeholder="Enter Lives" required oninput="calculateTotalLives(this)"> placeholder="Enter Lives" required oninput="calculateTotalLives(this)">
</div> </div>
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="incept_no_of_lives" class="total_title"> Total Lives at Inception <span <label for="incept_no_of_lives" class="total_title">
class="text-danger"></span></label> <span class="total_title_text">Total Lives at Inception</span>
<span class="text-danger">*</span>
</label>
<input value="<?= isset($lead_edit_data['incept_no_of_lives']) ? $lead_edit_data['incept_no_of_lives'] : '' ?>" type="text" class="form-control" id="incept_no_of_lives" name="incept_no_of_lives[]" <input value="<?= isset($lead_edit_data['incept_no_of_lives']) ? $lead_edit_data['incept_no_of_lives'] : '' ?>" type="text" class="form-control" id="incept_no_of_lives" name="incept_no_of_lives[]"
placeholder="Enter Lives" required> placeholder="Enter Lives" required>
</div> </div>

View File

@ -3,12 +3,16 @@
<div class="form-row" > <div class="form-row" >
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="incept_emp_count" class="emp_title"> No of Employees at Inception <span class="text-danger">*</span></label> <label for="incept_emp_count" class="emp_title">
<span class="emp_title_text"> No of Employees at Inception </span>
<span class="text-danger">*</span>
</label>
<input value="<?= isset($lead_edit_data['incept_emp_count']) ? $lead_edit_data['incept_emp_count'] : '' ?>" type="text" class="form-control" id="incept_emp_count" name="incept_emp_count[]" placeholder="Enter Lives" required> <input value="<?= isset($lead_edit_data['incept_emp_count']) ? $lead_edit_data['incept_emp_count'] : '' ?>" type="text" class="form-control" id="incept_emp_count" name="incept_emp_count[]" placeholder="Enter Lives" required>
</div> </div>
<div class="form-group col-md-4"> <div class="form-group col-md-4">
<label for="total_lives_at_incept" class="total_title"> Total Lives at Inception <span class="text-danger"></span></label> <label for="total_lives_at_incept" class="total_title">
<span class="total_title_text"> Total Lives at Inception </span> <span class="text-danger"></span></label>
<input value="<?= isset($lead_edit_data['total_lives_at_incept']) ? $lead_edit_data['total_lives_at_incept'] : '' ?>" type="text" class="form-control" id="total_lives_at_incept" name="total_lives_at_incept[]" placeholder="Enter Lives" disabled> <input value="<?= isset($lead_edit_data['total_lives_at_incept']) ? $lead_edit_data['total_lives_at_incept'] : '' ?>" type="text" class="form-control" id="total_lives_at_incept" name="total_lives_at_incept[]" placeholder="Enter Lives" disabled>
</div> </div>