';
}
diff --git a/api/application/models/Dash_Board_Model.php b/api/application/models/Dash_Board_Model.php
index 92f05ff0..656ec5f2 100644
--- a/api/application/models/Dash_Board_Model.php
+++ b/api/application/models/Dash_Board_Model.php
@@ -202,11 +202,34 @@ class Dash_Board_Model extends SPARQ_Model {
}
- public function PD_MIS_report()
+ public function PD_MIS_report($applicant_id = null,$from_date = null,$to_date = null,$city = null,$branch = null)
{
- $this->db->select('*');
- $this->db->from(PDMIS);
+ $this->db->SELECT('*');
+ $this->db->FROM(PDMIS);
+ if($applicant_id != null)
+ {
+ $this->db->LIKE('application_id',$applicant_id);
+ }
+ if($from_date != null)
+ {
+ $this->db->WHERE('date(triggered)>=',$from_date);
+ }
+ if($to_date != null)
+ {
+ $this->db->WHERE('date(triggered)<=',$to_date);
+ }
+ if($city != null)
+ {
+ $this->db->LIKE('city',$city);
+ }
+ if($branch != null)
+ {
+
+ $this->db->LIKE('branch',$branch);
+ }
+
$query = $this->db->get();
+ //print_r($this->db->last_query());
return $query->result();
}
diff --git a/api/application/models/PD_Model.php b/api/application/models/PD_Model.php
index 8f17df10..2cdd8a39 100644
--- a/api/application/models/PD_Model.php
+++ b/api/application/models/PD_Model.php
@@ -124,7 +124,7 @@ class PD_Model extends SPARQ_Model {
//PD List with Common Filters
- public function PDListwithGlobalFilters($pd_type,$pd_status,$pd_from_date,$pd_to_date,$pd_city,$pd_products,$pd_lender,$pd_applicant_name,$pd_applicant_lender_ref)
+ public function PDListwithGlobalFilters($pd_type,$pd_status,$pd_from_date,$pd_to_date,$pd_city,$pd_products,$pd_lender,$pd_applicant_name,$pd_applicant_lender_ref,$pd_officer_name)
{
$this->db->SELECT('PDTRIGGER.pd_id, PDTRIGGER.fk_lender_id,ENTITY.full_name as lender_full_name,ENTITY.short_name as lender_short_name,PDTRIGGER.fk_entity_billing_id,ENTITYBILLING.billing_name, PDTRIGGER.lender_applicant_id, DATE_FORMAT(PDTRIGGER.pd_date_of_initiation, "%d/%m/%Y") as pd_date_of_initiation, PDTRIGGER.fk_product_id,PRODUCTS.name as product_name,PRODUCTS.abbr as product_abbr, PDTRIGGER.fk_subproduct_id,SUBPRODUCTS.name as subproduct_name,SUBPRODUCTS.abbr as subproduct_abbr, PDTRIGGER.fk_pd_type,PDTYPE.type_name as pd_type_name, PDTRIGGER.pd_status,PDTRIGGER.pd_specific_clarification, DATE_FORMAT(PDTRIGGER.createdon,"%d/%m/%Y %H:%i:%s") as createdon, PDTRIGGER.fk_createdby, DATE_FORMAT(PDTRIGGER.updatedon,"%d/%m/%Y %H:%i:%s") as updatedon, PDTRIGGER.fk_updatedby,concat(USERPROFILE.first_name," ",USERPROFILE.last_name) as createdby,concat(USERPROFILE1.first_name," ",USERPROFILE1.last_name) as updatedby, PDTRIGGER.fk_pd_allocation_type,,PDALLOCATIONTYPE.pd_allocation_type_name, PDTRIGGER.fk_pd_allocated_to,concat(USERPROFILE2.first_name," ",USERPROFILE2.last_name) as pd_allocated_to,PDTRIGGER.executive_id,concat(EXECUTIVE.first_name," ",EXECUTIVE.last_name) as executive_name,PDTRIGGER.central_pd_officer_id,concat(CENTRALOFFICER.first_name," ",CENTRALOFFICER.last_name) as centralofficer,PDTRIGGER.fk_pd_template_id,TEMPLATE.template_name, PDTRIGGER.fk_customer_segment,CUSTOMERSEGMENT.name as customer_segment_name,CUSTOMERSEGMENT.abbr as customer_segment_abbr, PDTRIGGER.pd_officier_final_judgement, PDTRIGGER.pd_agency_id,AGENCY.full_name as agency_name, PDTRIGGER.loan_amount,PDTRIGGER.addressline1,PDTRIGGER.addressline2,PDTRIGGER.addressline3,PDTRIGGER.fk_city,CITY.name as city_name,PDTRIGGER.fk_state,STATE.name as state_name,PINCODE.pincode,PDTRIGGER.pincode as pincode_id,PDTRIGGER.pd_contact_person,PDTRIGGER.pd_contact_mobileno,DATE_FORMAT(PDTRIGGER.scheduled_on,"%d/%m/%Y %h:%i %p") as scheduled_on,DATE_FORMAT(PDTRIGGER.completed_on,"%d/%m/%Y %h:%i:%s %p") as completed_on,PDTRIGGER.remarks,PDTRIGGER.is_original_report_created,PDTRIGGER.pd_report_latest_version,PDTRIGGER.pd_branch_id,ENTITYLENDERBRANCH.branch_name,PDTRIGGER.qc_feedback,PDTRIGGER.qc_rating,PDTRIGGER.qc_remarks,PDTRIGGER.lender_rating,PDTRIGGER.lender_feedback,PDTRIGGER.other_pincode,PDAPPLICANTSDETAILS.applicant_name,PDTRIGGER.is_otp_done,PDTRIGGER.is_child');
@@ -188,6 +188,10 @@ class PD_Model extends SPARQ_Model {
{
$this->db->LIKE('PDAPPLICANTSDETAILS.applicant_name',"$pd_applicant_name");
}
+ if($pd_officer_name != "" || $pd_officer_name != null )
+ {
+ $this->db->LIKE('concat(USERPROFILE2.first_name," ",USERPROFILE2.last_name)',$pd_officer_name);
+ }
$this->db->ORDER_BY('PDTRIGGER.pd_id','DESC');
@@ -408,7 +412,7 @@ class PD_Model extends SPARQ_Model {
$arrayForText = array("fk_lender_id" => "Lender", "fk_entity_billing_id" => "Billing ID", "lender_applicant_id" => "Applicant Ref ID", "pd_date_of_initiation" => "PD Date of Initiation", "fk_product_id" => "Product", "fk_subproduct_id" => "Sub Product","fk_pd_type" => "PD Type", "pd_status" => "PD Status", "pd_specific_clarification"=> "PD Specific Clarification","fk_pd_allocation_type" => "Allocation Type", "fk_pd_allocated_to" => "Allocated Person", "fk_pd_template_id" => "PD Tempale", "fk_customer_segment" => "Customer Segment", "pd_officier_final_judgement" => "PD Officer Finale Judgement", "pd_agency_id" => "PD Agency", "loan_amount" => "Loan Amount", "addressline1" => "Addressline1", "addressline2" => "Addressline1", "addressline3" => "Addressline1", "fk_city" => "City", "fk_state" => "State", "pincode" => "Pincode", "bounce_reason" => "Bounce Reason", "executive_id" => "PD Executive","central_pd_officer_id"=>"Central PD Officer","pd_contact_person" => "Lender Contact Person", "pd_contact_mobileno" => "Lender Contact Mobile Number", "scheduled_on" => "Scheduled On", "completed_on" => "Completed On",'fk_address_id' => 'PD Address Map','fk_primary_address_id' => 'Primary Address');
- $this->db->SELECT('COMMONMASTER.log_id, COMMONMASTER.primary_key, COMMONMASTER.table_name, COMMONMASTER.field_name, COMMONMASTER.old_value, COMMONMASTER.new_value, COMMONMASTER.fk_createdby, DATE_FORMAT(COMMONMASTER.createdon,"%dth %b %Y at %h:%i:%s %p") as createdon,concat(USERPROFILE.first_name," ",USERPROFILE.last_name) as createdby,ENTITYBILLINGOLD.billing_name as old_billing_name,ENTITYBILLINGNEW.billing_name as new_billing_name,ENTITYOLD.full_name as old_entity_name,ENTITYNEW.full_name as new_entity_name,PRODUCTSOLD.abbr as old_product,PRODUCTSNEW.abbr as new_product,SUBPRODUCTSOLD.abbr as old_sub_product,SUBPRODUCTSNEW.abbr as new_sub_product,PDTYPEOLD.type_name as old_type_name,PDTYPENEW.type_name as new_type_name,concat(ALLOCATEDOLD.first_name," ",ALLOCATEDOLD.last_name) as old_allocated_to,concat(ALLOCATEDNEW.first_name," ",ALLOCATEDNEW.last_name) as new_allocated_to,TEMPLATEOLD.template_name as old_template_name,TEMPLATENEW.template_name as new_template_name,CUSTOMERSEGMENTOLD.name as old_cs_name,CUSTOMERSEGMENTNEW.name as new_cs_name,AGENCYOLD.full_name as old_agencyname,AGENCYNEW.full_name as new_agencyname,CITYOLD.name as old_city,CITYNEW.name as new_city,STATEOLD.name as old_state,STATENEW.name as new_state,concat(EXECUTIVEOLD.first_name," ",EXECUTIVEOLD.last_name) as old_executive,concat(EXECUTIVENEW.first_name," ",EXECUTIVENEW.last_name) as new_executive,concat(CENTRALPDOLD.first_name," ",CENTRALPDOLD.last_name) as old_central_pd_officer_id,concat(CENTRALPDNEW.first_name," ",CENTRALPDNEW.last_name) as new_central_pd_officer_id,ALLOCATIONOLD.pd_allocation_type_name as old_allocation_type,ALLOCATIONNEW.pd_allocation_type_name as new_allocation_type,BOUNCEMASTEROLD.bounce_reason_name as old_bounce_reason,BOUNCEMASTERNEW.bounce_reason_name as new_bounce_reason,PINCODEOLD.pincode as old_pincode,PINCODENEW.pincode as new_pincode,PDTRIGGER.other_pincode');
+ $this->db->SELECT('COMMONMASTER.log_id, COMMONMASTER.primary_key, COMMONMASTER.table_name, COMMONMASTER.field_name, COMMONMASTER.old_value, COMMONMASTER.new_value, COMMONMASTER.fk_createdby, DATE_FORMAT(COMMONMASTER.createdon,"%D %b %Y at %h:%i:%s %p") as createdon,concat(USERPROFILE.first_name," ",USERPROFILE.last_name) as createdby,ENTITYBILLINGOLD.billing_name as old_billing_name,ENTITYBILLINGNEW.billing_name as new_billing_name,ENTITYOLD.full_name as old_entity_name,ENTITYNEW.full_name as new_entity_name,PRODUCTSOLD.abbr as old_product,PRODUCTSNEW.abbr as new_product,SUBPRODUCTSOLD.abbr as old_sub_product,SUBPRODUCTSNEW.abbr as new_sub_product,PDTYPEOLD.type_name as old_type_name,PDTYPENEW.type_name as new_type_name,concat(ALLOCATEDOLD.first_name," ",ALLOCATEDOLD.last_name) as old_allocated_to,concat(ALLOCATEDNEW.first_name," ",ALLOCATEDNEW.last_name) as new_allocated_to,TEMPLATEOLD.template_name as old_template_name,TEMPLATENEW.template_name as new_template_name,CUSTOMERSEGMENTOLD.name as old_cs_name,CUSTOMERSEGMENTNEW.name as new_cs_name,AGENCYOLD.full_name as old_agencyname,AGENCYNEW.full_name as new_agencyname,CITYOLD.name as old_city,CITYNEW.name as new_city,STATEOLD.name as old_state,STATENEW.name as new_state,concat(EXECUTIVEOLD.first_name," ",EXECUTIVEOLD.last_name) as old_executive,concat(EXECUTIVENEW.first_name," ",EXECUTIVENEW.last_name) as new_executive,concat(CENTRALPDOLD.first_name," ",CENTRALPDOLD.last_name) as old_central_pd_officer_id,concat(CENTRALPDNEW.first_name," ",CENTRALPDNEW.last_name) as new_central_pd_officer_id,ALLOCATIONOLD.pd_allocation_type_name as old_allocation_type,ALLOCATIONNEW.pd_allocation_type_name as new_allocation_type,BOUNCEMASTEROLD.bounce_reason_name as old_bounce_reason,BOUNCEMASTERNEW.bounce_reason_name as new_bounce_reason,PINCODEOLD.pincode as old_pincode,PINCODENEW.pincode as new_pincode,PDTRIGGER.other_pincode');
$this->db->FROM(COMMONMASTER.' as COMMONMASTER');
$this->db->JOIN(USERPROFILE.' as USERPROFILE','COMMONMASTER.fk_createdby = USERPROFILE.userid','LEFT');
$this->db->JOIN(ENTITYBILLING.' as ENTITYBILLINGOLD','COMMONMASTER.old_value = ENTITYBILLINGOLD.entity_billing_id','LEFT');
diff --git a/api/application/views/report_templates/JSONTOREPORT.php b/api/application/views/report_templates/JSONTOREPORT.php
index 5c90b493..20e1b44d 100644
--- a/api/application/views/report_templates/JSONTOREPORT.php
+++ b/api/application/views/report_templates/JSONTOREPORT.php
@@ -439,11 +439,11 @@ defined('BASEPATH') OR exit('No direct script access allowed');
-
@@ -1453,8 +1459,8 @@ defined('BASEPATH') OR exit('No direct script access allowed');
0){ ?>
-
-
+
Key Products and Area of Operations
+
@@ -1505,8 +1511,8 @@ defined('BASEPATH') OR exit('No direct script access allowed');
0){ ?>
-
-
+
Key Products and Area of Operations
+
@@ -1558,8 +1564,8 @@ defined('BASEPATH') OR exit('No direct script access allowed');
0){ ?>
-
-
+
Key Products and Area of Operations
+
@@ -1644,14 +1650,14 @@ defined('BASEPATH') OR exit('No direct script access allowed');
As per person`s met, applicant using Mobile Wallets/UPI for business transactions.';
+ echo '
As per Person(s) met, the applicant is using Mobile Wallets/UPI for business transactions.
';
}//else
//{
// echo '
As per person`s met,applicant using Mobile Wallets/UPI for business transactions.
The applicant has using the following POS machines:
';
echo '
';
echo '
Name of the Financial Insitution
TID Number of POS machine
';
foreach($fetchRow['pos_machines_details'] as $pos)
@@ -3443,7 +3449,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
$intro_text = ''.$fmValue['selected_person_title'].$fmValue['selected_person'].'Family Information - Select person for capturing family details, who is an applicant in the case, resides at '.$fmValue['residency_address'].'Family Information - Residence Address of Select person .';
$residence_text ='This is a '. $fmValue['residence_ownership'].' Family Information - Ownership of Residence residence, where the applicant has been staying for '. $fmValue['residence_No_of_years'].'Family Information - No of Yrs in current residence .';
- $residence_text .= (!strcasecmp($fmValue['residence_ownership'],'rented')) ? ' The rent paid Rs.'.$fmValue['rent'].' per month.' : '';
+ $residence_text .= (!strcasecmp($fmValue['residence_ownership'],'rented')) ? ' The rent paid '.$rupee_symbol.' '.$fmValue['rent'].' per month.' : '';
echo $intro_text;echo "
";echo $residence_text;
@@ -3665,14 +3671,14 @@ defined('BASEPATH') OR exit('No direct script access allowed');
-
Polite
+
Polite
-
Rude
+
Rude
-
Others*
+
Others*
@@ -3884,7 +3890,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
Detailed Score Card Section" ;