diff --git a/api/application/controllers/PD_Controller.php b/api/application/controllers/PD_Controller.php index 47263925..25c41250 100644 --- a/api/application/controllers/PD_Controller.php +++ b/api/application/controllers/PD_Controller.php @@ -4703,14 +4703,17 @@ class PD_Controller extends REST_Controller if(!empty($applicant_details)){ $this->toMakeFaceBoundingBox($pdid,$data['pd_master_details'][0]['fk_lender_id']); } - $db_result = $this->PD_Model->selectCustomRecords(array('facecrop'), array('fk_pd_id' => $pdid,'isactive'=>1,'facemark_image_generated'=>1), PDAPPLICANTSDETAILS); + $db_result = $this->PD_Model->selectCustomRecords(array('facecrop','pd_co_applicant_id'), array('fk_pd_id' => $pdid,'isactive'=>1,'facemark_image_generated'=>1), PDAPPLICANTSDETAILS); $fc_array = array(); if(!empty($db_result)){ - for ($dinx = 0; $dinx < count($db_result); $dinx++) { - $string = $db_result[$dinx]['facecrop']; - // echo gettype($string); - $fc_array[$dinx] = json_decode($string, true); - } + for ($dinx = 0; $dinx < count($db_result); $dinx++) { + $string = $db_result[$dinx]['facecrop']; + // echo gettype($string); + $json_decode = json_decode($string, true); + $fc_array[$dinx]['compare_image'] = !empty($json_decode[0]['compare_image']) ? $json_decode[0]['compare_image'] :array() ; + $fc_array[$dinx]['source_image'] = !empty($json_decode[1]['source_image']) ? $json_decode[1]['source_image'] :array() ; + $fc_array[$dinx]['co_applicant_id'] = $db_result[$dinx]['pd_co_applicant_id']; + } } $data['facecrop'] = $fc_array; // echo "i ahve image"; @@ -5880,13 +5883,16 @@ class PD_Controller extends REST_Controller } } - $db_result = $this->PD_Model->selectCustomRecords(array('facecrop'), array('fk_pd_id' => $pdid,'isactive'=>1,'facemark_image_generated'=>1), PDAPPLICANTSDETAILS); + $db_result = $this->PD_Model->selectCustomRecords(array('facecrop','pd_co_applicant_id'), array('fk_pd_id' => $pdid,'isactive'=>1,'facemark_image_generated'=>1), PDAPPLICANTSDETAILS); $fc_array = array(); if(!empty($db_result)){ for ($dinx = 0; $dinx < count($db_result); $dinx++) { $string = $db_result[$dinx]['facecrop']; // echo gettype($string); - $fc_array[$dinx] = json_decode($string, true); + $json_decode = json_decode($string, true); + $fc_array[$dinx]['compare_image'] = !empty($json_decode[0]['compare_image']) ? $json_decode[0]['compare_image'] :array() ; + $fc_array[$dinx]['source_image'] = !empty($json_decode[1]['source_image']) ? $json_decode[1]['source_image'] :array() ; + $fc_array[$dinx]['co_applicant_id'] = $db_result[$dinx]['pd_co_applicant_id']; } } $data['facecrop'] = $fc_array; diff --git a/api/application/helpers/video_grabber_helper.php b/api/application/helpers/video_grabber_helper.php index 476b9571..eb6557d6 100644 --- a/api/application/helpers/video_grabber_helper.php +++ b/api/application/helpers/video_grabber_helper.php @@ -21,8 +21,8 @@ class video_grabber_helper if($pd_category == '1'){ $pd_master_details = $CI->PD_Model->getPDMasterDetails($pd_id,$random_string);} } - // $bucket_name = LENDER_BUCKET_NAME_PREFIX.$pd_master_details[0]['fk_lender_id']; - $bucket_name = TWILIO_CONTENT_BUCKET_NAME; + $old_bucket_name = LENDER_BUCKET_NAME_PREFIX.$pd_master_details[0]['fk_lender_id']; + $new_bucket_name = TWILIO_CONTENT_BUCKET_NAME; $result_data = array(); $query = "SELECT * FROM ".VIDEO_ROOM_INFO." where fk_pd_id = $pdid and isactive = 1 and pd_category = $pd_category"; @@ -42,8 +42,13 @@ class video_grabber_helper if($value['s3_copied']) { - // $final_key = 'pd'.$pd_master_details[0]['pd_id'].'/video/'.$file_name; - $final_key = $file_name; + if($value['s3_copied'] == 1){ + $final_key = 'pd'.$pd_master_details[0]['pd_id'].'/video/'.$file_name; + $bucket_name = $old_bucket_name; + }else if($value['s3_copied'] == 0){ + $final_key = $file_name; + $bucket_name = $new_bucket_name; + } $singed_uri = $CI->aws_s3->getSingleObjectInaBucketAsSignedURI($bucket_name,$final_key,'+7 days'); $shortURL = VIDEO_SHORT_URL . substr($video_name,0,6); diff --git a/api/application/views/report_templates/JSONTOREPORT_CLIX.php b/api/application/views/report_templates/JSONTOREPORT_CLIX.php index 07b2349f..e780740d 100644 --- a/api/application/views/report_templates/JSONTOREPORT_CLIX.php +++ b/api/application/views/report_templates/JSONTOREPORT_CLIX.php @@ -468,12 +468,15 @@ defined('BASEPATH') OR exit('No direct script access allowed'); padding: 5px; /*margin: 10px;*/ } -.facecrop { box-sizing: border-box; } -.facecrop_row { display: flex; } +/* .facecrop { box-sizing: border-box; } +.facecrop_row { display: flex; } */ /* Create three equal columns that sits next to each other */ -.facecrop_column { flex: 33.33%; padding: 5px;} +/* .facecrop_column { flex: 33.33%; padding: 5px;} */ /* ######### TOOLTIP CSS END ######### */ - +/* #########Person Met,FaceCrop Table Styles######### */ + .person_table { border-collapse: collapse; width: 100%; page-break-inside: avoid; } + .person_table td { padding: 8px; } +/* #########End of Person Met,FaceCrop Table Styles######### */