diff --git a/app/Controllers/MasterController.php b/app/Controllers/MasterController.php
index 4e1271f8..7a09ce13 100755
--- a/app/Controllers/MasterController.php
+++ b/app/Controllers/MasterController.php
@@ -1422,6 +1422,7 @@ class MasterController extends AdminController
if ($insert) {
//for CD Tranction Table
+ $cd_tranction_data['cd_ac_pk'] = $this->CDMasterModel->insertID();
$response = DepositHelper::saveDeposit($cd_tranction_data, $loggedInUserID);
$cd_data = $this->CDMasterModel->where('client_id', $data['client_id'])->where('insurer_id', $data['insurer_id'])->findAll();
diff --git a/app/Models/PolicyTransactionModel.php b/app/Models/PolicyTransactionModel.php
index 2a77d201..1f19a388 100644
--- a/app/Models/PolicyTransactionModel.php
+++ b/app/Models/PolicyTransactionModel.php
@@ -783,6 +783,19 @@ class PolicyTransactionModel extends Model
->join('user_profiles AS service_user', 'policy_transaction.serviced_by = service_user.id', 'left')
->where('policy_transaction.is_active', 1)
->where('pt_co_share_details.is_active', 1);
+
+ if (
+ (!in_array(get_role_id(), [1, 5])) &&
+ !(
+ in_array(MANAGEMENT_TEAM_ID, user_team()) ||
+ in_array(FINANCE_TEAM_ID, user_team()) ||
+ in_array(BUSINESS_TEAM_ID, user_team())
+ )
+ ) {
+ if (get_role_id() == 4 && in_array(POS_TEAM_ID, user_team())) {
+ $builder->where('policy_transaction.created_by', get_session_userid());
+ }
+ }
// Check if the start date and end date are provided
if ($start_date != 0 && $end_date != 0 && $date_type != 0 && $date_type != 'statement_month') {
diff --git a/app/Views/layout/header.php b/app/Views/layout/header.php
index 8db290b2..3491cacb 100755
--- a/app/Views/layout/header.php
+++ b/app/Views/layout/header.php
@@ -732,9 +732,9 @@
-
+
-
+
@@ -745,68 +745,76 @@
BDS
+
+
+ Variance
+
+
+ Outstanding
+
+
+ IRDA Reports
+
+
+ Renewal Reports
+
+
+
+
+
+
+
+
+
+
+
+ Policy Pending Actions
+
+
+
+
+
+
+
+
+
+ Masters
+
+
-
-
-
- Policy Pending Actions
-
-
-
-
-
-
-
- Masters
-
-
-
-
-
-
-
- Documents
-
-
+
+
+
+
+ Documents
+
+
+
diff --git a/app/Views/policy_transaction_endorsement_form.php b/app/Views/policy_transaction_endorsement_form.php
index 6e1ba143..d415c044 100644
--- a/app/Views/policy_transaction_endorsement_form.php
+++ b/app/Views/policy_transaction_endorsement_form.php
@@ -1769,7 +1769,7 @@ function addInsurerColumn() {
break;
}
- }else if(team_id.includes('3')){
+ }else if(team_id.includes('3') || team_id.includes('8')){
switch(index) {
case 0: // Insurer selection
@@ -2155,7 +2155,7 @@ function populateTable(dataArray, status = false) {
cell.find('input[type="hidden"]').val(status ? data.id : '');
break;
}
- }else if(team_id.includes('3')){
+ }else if(team_id.includes('3') || team_id.includes('8')){
switch (rowIndex) {
case 0: // Insurer selection
cell.find('select').val(insurer);
diff --git a/app/Views/policy_transaction_inception_form.php b/app/Views/policy_transaction_inception_form.php
index 11f601cc..f88a44fa 100644
--- a/app/Views/policy_transaction_inception_form.php
+++ b/app/Views/policy_transaction_inception_form.php
@@ -3917,7 +3917,7 @@ function addInsurerColumn() {
}
- }else if(team_id.includes('3')){
+ }else if(team_id.includes('3') || team_id.includes('8')){
switch(index) {
case 0: // Insurer selection
@@ -4312,7 +4312,7 @@ function populateTable(dataArray, cd_ac_pk) {
cell.find('input[type="hidden"]').val(data.id);
break;
}
- }else if(team_id.includes('3')){
+ }else if(team_id.includes('3') || team_id.includes('8')){
switch (rowIndex) {
case 0: // Insurer selection