624 lines
22 KiB
PHP
624 lines
22 KiB
PHP
<?php
|
|
defined('BASEPATH') OR exit('No direct script access allowed');
|
|
|
|
$uparrow = '<span style="color:green;">↑</span>';
|
|
$downarrow = '<span style="color:red;">↓</span>';
|
|
$dash = '<span style="color:black;"> </span>';
|
|
$product_name = $master[0]['abbr'];
|
|
$rupee_symbol = "<span style='font-family: DejaVu Sans; sans-serif;font-size:10px'>₹</span>";
|
|
$title = "";
|
|
if($master[0]['sales_pd_type'] == 1){$title = "Physical "; }else if($master[0]['sales_pd_type'] == 2){$title = "Tele ";}
|
|
$smc_emp_code = $master[0]['smc_emp_code'];
|
|
//print_r($master[0]['abbr']);die();
|
|
?><!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
|
<title></title>
|
|
<link href="https://fonts.googleapis.com/css?family=Merriweather" rel="stylesheet">
|
|
<style type="text/css">
|
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
|
|
|
.page_break { page-break-before: always; }
|
|
#page_break { page-break-before: always; }
|
|
/*.page { width: 100%; height: 95%; }*/
|
|
@page {
|
|
margin: 100px 50px;
|
|
/*font-family:Helvetica,Arial;*/
|
|
font-family:Merriweather;
|
|
}
|
|
header {
|
|
position: fixed;
|
|
top: -70px;
|
|
left: 0px;
|
|
right: 0px;
|
|
height: 20px;
|
|
|
|
/** Extra personal styles **/
|
|
/*background-color: #03a9f4;
|
|
color: white;*/
|
|
text-align: right;
|
|
/*line-height: 35px;*/
|
|
}
|
|
footer {
|
|
position: fixed;
|
|
bottom: 5px;
|
|
left: 0px;
|
|
right: 0px;
|
|
height: 20px;
|
|
font-size: 10px;
|
|
|
|
/** Extra personal styles **/
|
|
/*background-color: #03a9f4;
|
|
color: white;*/
|
|
text-align: left;
|
|
/*line-height: 35px;*/
|
|
}
|
|
|
|
|
|
/* #########Score Card Table Styles######### */
|
|
|
|
.scorecard_table {
|
|
/* font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;*/
|
|
/*font-family: Merriweather;*/
|
|
border-collapse: collapse;
|
|
width: 100%;
|
|
page-break-inside: inline;
|
|
|
|
}
|
|
|
|
.scorecard_table td, .scorecard_table th {
|
|
border: 1px solid #000;
|
|
padding: 8px;
|
|
page-break-inside: inline;
|
|
|
|
|
|
}
|
|
|
|
.scorecard_table tr:nth-child(even){background-color: #f2f2f2;page-break-inside: inline; }
|
|
|
|
.scorecard_table tr:hover {background-color: #ddd;}
|
|
|
|
.scorecard_table th {
|
|
padding-top: 8px;
|
|
padding-bottom: 8px;
|
|
text-align: center;
|
|
background-color: #0191ed;
|
|
color: white;page-break-inside: inline;
|
|
|
|
}
|
|
|
|
/* #########End of Score Card Table Styles######### */
|
|
|
|
|
|
/* #########Score Card2 Table Styles######### */
|
|
|
|
.scorecard_table2 {
|
|
/* font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;*/
|
|
/*font-family: Merriweather;*/
|
|
border-collapse: collapse;
|
|
width: 100%;
|
|
page-break-inside: avoid;
|
|
|
|
}
|
|
|
|
.scorecard_table2 td, .scorecard_table2 th {
|
|
border: 1px solid #000;
|
|
padding: 8px;
|
|
page-break-inside: avoid;
|
|
|
|
|
|
}
|
|
|
|
.scorecard_table2 tr:nth-child(even){background-color: #f2f2f2;page-break-inside: avoid; }
|
|
|
|
.scorecard_table2 tr:hover {background-color: #ddd;}
|
|
|
|
.scorecard_table2 th {
|
|
padding-top: 8px;
|
|
padding-bottom: 8px;
|
|
text-align: center;
|
|
background-color: #0191ed;
|
|
color: white;page-break-inside: avoid;
|
|
|
|
}
|
|
|
|
/* #########End of Score Card 2 Table Styles######### */
|
|
|
|
.tdcenteralign{ text-align: center; }
|
|
.thlargefont{ font-size: 20px; }
|
|
|
|
</style>
|
|
|
|
|
|
</head>
|
|
<body style="font-family:Merriweather;font-size:12px;margin:15px 30px">
|
|
|
|
|
|
<footer>
|
|
<hr>
|
|
<img style="width:100px;height:50px;opacity: 0.5;padding-top: 5px;" src='https://pdgenie.com/logo/sineedge_red.png'/> Powered By PD Genie
|
|
</footer>
|
|
<header>
|
|
|
|
<div><img style="width:100px;height:50px;opacity: 0.5;" src='https://pdgenie.com/logo/smc_logo.png'/></div>
|
|
<hr>
|
|
</header>
|
|
|
|
<table class="scorecard_table">
|
|
|
|
<tbody>
|
|
<tr>
|
|
<th class="thlargefont" colspan="10" ><?php echo $title ?>Personal Discussion by Sales Team - <?php echo $product_name; ?> </th>
|
|
|
|
</tr>
|
|
<!-- <tr>
|
|
<td colspan="3"> Application ID</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['application_id'] ? $section1['application_id'] : 'Not Provided'?> </td>
|
|
</tr> -->
|
|
<tr>
|
|
|
|
<td colspan="3"> Name of Main Loan Applicant</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['main_loan_applicant']?> </td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3"> Name of the Company/Firm</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['company_name']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3"><?php if($master[0]['sales_pd_type'] == 1){echo 'Name of Person Met during visit'; }else{ echo 'Name of the Person Contacted'; } ?></td>
|
|
<td class = "tdcenteralign" colspan="7"><?php echo $section1['person_met_during_visit']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" rowspan="2" ><?php if($master[0]['sales_pd_type'] == 1){echo 'Address Visited'; }else{ echo 'Business Address'; } ?></td>
|
|
<td class = "tdcenteralign" colspan="7"><?php echo $section1['address_visited']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td>City</td>
|
|
<td class = "tdcenteralign"><?php echo $section1['city']?></td>
|
|
<td>State</td>
|
|
<td class = "tdcenteralign"><?php echo $section1['state']?></td>
|
|
<td>PIN</td>
|
|
<td class = "tdcenteralign" colspan="2"><?php if(isset($section1['pincode_others'])){ echo $section1['pincode_others']; } else { echo $section1['pincode']; }?></td>
|
|
</tr>
|
|
|
|
<?php if( $master[0]['sales_pd_type'] == 2){ ?>
|
|
|
|
<tr>
|
|
<td colspan="3">Applicant qualification</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['applicant_qualification'];?></td>
|
|
<tr>
|
|
<td colspan="3">Mother's Name</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['mother_name'];?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3">Official Email ID</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['official_emailid'];?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3">Current residence Address</td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['current_residence_address'];?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3">Current residence Address ownership (Rented/Owned) </td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['current_residence_ownership'];?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3">Business address/office address (Rented/Owned) </td>
|
|
<td class = "tdcenteralign" colspan="7"> <?php echo $section1['business_office_address'];?></td>
|
|
</tr>
|
|
<?php } ?>
|
|
</tbody>
|
|
</table>
|
|
<br>
|
|
<table class="scorecard_table">
|
|
<tbody>
|
|
<tr>
|
|
<th class="thlargefont" colspan="10">Fund Requirement</th>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" >Loan Amount Applied for (Rs)</td>
|
|
<td class = "tdcenteralign" colspan="3" ><?php echo $rupee_symbol.' '.MYUTIL::customIndianNumberFormat($section2['loan_amount_applied'])?></td>
|
|
<td colspan="2">Total Fund Requirement (Rs)</td>
|
|
<td class = "tdcenteralign" colspan="2"> <?php echo $rupee_symbol.' '. MYUTIL::customIndianNumberFormat($section2['total_fund_requirement'])?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" >Loan Tenure (Months)</td>
|
|
<td class = "tdcenteralign" colspan="3" ><?php echo $section2['loan_tenure']?></td>
|
|
<td colspan="2" >Loan Purpose (End-Use)</td>
|
|
<td class = "tdcenteralign" colspan="2" ><?php echo $section2['loan_purpose']?></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<!-- initially br statement due to extra question. changed to page break condition -->
|
|
<?php if( $master[0]['sales_pd_type'] == 2){
|
|
?> <div id="page_break"></div> <?php } else { ?> <br> <?php } ?>
|
|
<table class="scorecard_table" style="table-layout: fixed">
|
|
<tbody>
|
|
<tr>
|
|
<th class="thlargefont" colspan="10">Details of Key Stakeholders in the Business</th>
|
|
</tr>
|
|
<tr>
|
|
<th colspan="6">Name</th>
|
|
<th colspan="2" >Share Holding</th>
|
|
<th colspan="2" >Year(s) in Current Business</th>
|
|
<!-- <th colspan="1">Total Work Exp(Yrs)</th>
|
|
<th colspan="3" >Previous Experience Details</th>
|
|
<th colspan="2" >Started Business</th> -->
|
|
</tr>
|
|
<?php
|
|
if($section3)
|
|
{
|
|
|
|
foreach ($section3 as $section3_key => $section3_value)
|
|
{
|
|
echo '<tr><td class="tdcenteralign" colspan="6">'.$section3_value['name'] .'</td>'.
|
|
'<td class="tdcenteralign" colspan="2">'.$section3_value['share_holding'].'%</td>'.
|
|
'<td class="tdcenteralign" colspan="2">'.$section3_value['vintage_in_current_biz'].'</td>'.'</tr>';
|
|
//'<td class="tdcenteralign" colspan="1">'.$section3_value['total_work_exp'].'</td>'.
|
|
|
|
//'<td class="tdcenteralign" colspan="3">'.( isset ($section3_value['previous_experience_details']) && $section3_value['previous_experience_details'] ? $section3_value['previous_experience_details'] : 'NA' ).'</td>'.
|
|
//'<td class="tdcenteralign" colspan="2" style="text-align: center">'.$section3_value['started_biz'].'</td>'.
|
|
//'</tr>';
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
<tr>
|
|
<th class="thlargefont" colspan="10" >Brief of the Business / Service</th>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="4" style="text-align: left;word-wrap:break-word;table-layout:fixed;">Nature of business</td><td colspan="6" style="text-align: center;word-wrap:break-word;table-layout:fixed;"><?php echo $section4['nature_of_business']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="4" style="text-align: left;word-wrap:break-word;table-layout:fixed;">Product/Service Type</td><td colspan="6" style="text-align: center;word-wrap:break-word;table-layout:fixed;"><?php echo $section4['product_service_type']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="4" style="text-align: left;word-wrap:break-word;table-layout:fixed;">Other Information</td><td colspan="6" style="text-align: center;word-wrap:break-word;table-layout:fixed;"><?php echo $section4['other_information']?></td>
|
|
</tr>
|
|
<!-- <tr></tr><tr></tr><tr></tr> -->
|
|
</tbody></table>
|
|
|
|
<div id="page_break"></div>
|
|
<table class="scorecard_table">
|
|
<tr>
|
|
<th class="thlargefont" colspan="10" >Financial Information</th>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="6" >Name of the Company / Firm whose financials are noted </td>
|
|
<td class = "tdcenteralign" colspan="4" ><?php echo $section1['company_name']?></td>
|
|
</tr>
|
|
</tbody></table>
|
|
<table class="scorecard_table"><tbody>
|
|
<tr>
|
|
<th colspan="7">Particulars of Financials as per books of Accounts</th>
|
|
<?php
|
|
|
|
$sales_pd_created_date = date('Y-m-d',strtotime($master[0]['createdon']));
|
|
$last_four_finyrs = MYUTIL::getFinYears($sales_pd_created_date,1);
|
|
$ordered_finyrs_data = MYUTIL::reOrderFinYrsData($section5,$last_four_finyrs);
|
|
|
|
//print_r($section5);die();
|
|
$totol = 0;
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
$totol++;
|
|
echo '<th colspan="1" >FY - '.($fy_value['fy']).'</th>';
|
|
}
|
|
}
|
|
?>
|
|
|
|
</tr>
|
|
|
|
|
|
<tr>
|
|
<td colspan="7">Sales / Revenue (Rs) </td>
|
|
<?php
|
|
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">'. $rupee_symbol.' '.MYUTIL::customIndianNumberFormat(($fy_value['sales_revenue'])).'</td>';
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="7" >Net Profit / (Net Loss) (Rs) </td>
|
|
<?php
|
|
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">'.$rupee_symbol.' '. MYUTIL::customIndianNumberFormat($fy_value['net_profit']).'</td>';
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="7" >Net Profit or (Net Loss) to Sales % </td>
|
|
<?php
|
|
|
|
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">'.round((($fy_value['net_profit'] / $fy_value['sales_revenue'] ) * 100 ),2).'%</td>';
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="7" >% <?php echo '( '.$uparrow.'/'.$downarrow.' )'?> in Sales over PY </td>
|
|
<?php
|
|
|
|
$pre_year_sales = 0;
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
|
|
|
|
if($fy_key == 0)
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">NA</td>';
|
|
}
|
|
else
|
|
{
|
|
//echo $pre_year_sales;
|
|
$sales_over_py = round( ((($fy_value['sales_revenue'] - $pre_year_sales) / $pre_year_sales ) * 100),2);
|
|
|
|
|
|
echo '<td colspan="1"class="tdcenteralign" >'. ((($sales_over_py == 0 ) ? $dash :( $sales_over_py > 0 ? $uparrow : $downarrow))).'' . abs($sales_over_py). ' %</td>';
|
|
|
|
}
|
|
$pre_year_sales = $fy_value['sales_revenue'];
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="7" >% <?php echo '( '.$uparrow.'/'.$downarrow.' )'?> in Net Profit over PY </td>
|
|
<?php
|
|
|
|
$pre_year_net_profit = 0;
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
if($fy_key == 0)
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">NA</td>';
|
|
}
|
|
else
|
|
{
|
|
$net_profit_over_py = round( ((($fy_value['net_profit'] - $pre_year_net_profit) / $pre_year_net_profit ) * 100),2);
|
|
echo '<td colspan="1" class="tdcenteralign">'. ((($net_profit_over_py == 0 ) ? $dash :( $net_profit_over_py > 0 ? $uparrow : $downarrow))).' ' . abs($net_profit_over_py). '% </td>';
|
|
|
|
}
|
|
$pre_year_net_profit = $fy_value['net_profit'];
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="7" >% <?php echo '( '.$uparrow.'/'.$downarrow.' )'?> in Net Profit % over PY </td>
|
|
<?php
|
|
|
|
$pre_year_net_pro_loss_per = 0;
|
|
foreach ($ordered_finyrs_data as $fy_key => $fy_value)
|
|
{
|
|
if(is_numeric($fy_key))
|
|
{
|
|
if($fy_key == 0)
|
|
{
|
|
echo '<td colspan="1" class="tdcenteralign">NA</td>';
|
|
}
|
|
else
|
|
{
|
|
$year_net_pro_loss_per_over_py = round( ((( (($fy_value['net_profit'] / $fy_value['sales_revenue'] ) * 100 ) - $pre_year_net_pro_loss_per) / $pre_year_net_pro_loss_per ) * 100),2);
|
|
|
|
|
|
echo '<td colspan="1" class="tdcenteralign">'. ((($year_net_pro_loss_per_over_py == 0 ) ? $dash :( $year_net_pro_loss_per_over_py > 0 ? $uparrow : $downarrow))).' ' . abs($year_net_pro_loss_per_over_py). '% </td>';
|
|
// echo '<td colspan="1" >'. (($year_net_pro_loss_per_over_py > 0 )? '<span style="color:green;">↑</span>' : '<span style="color:red;">↓</span>').' ( ' . $year_net_pro_loss_per_over_py. ' )</td>'; //(($fy_value['net_profit'] / $fy_value['sales_revenue'] ) * 100 )
|
|
|
|
}
|
|
$pre_year_net_pro_loss_per = (($fy_value['net_profit'] / $fy_value['sales_revenue'] ) * 100 );
|
|
}
|
|
}
|
|
?>
|
|
</tr>
|
|
</tbody></table>
|
|
<br>
|
|
<table class="scorecard_table">
|
|
<tr>
|
|
<td colspan="3">Income to be Considered (Rs Per Annum) </td>
|
|
<td class="tdcenteralign" colspan="2"><?php echo $rupee_symbol.' '.MYUTIL::customIndianNumberFormat($section5['income_considered'] )?></td>
|
|
<td colspan="3" ><?php if( $master[0]['sales_pd_type'] == 2){ echo "Margin %"; } else { echo "Income Considered (Rs Per Mth)"; } ?></td>
|
|
<td class="tdcenteralign" colspan="2"><?php echo MYUTIL::customIndianNumberFormat( round(($section5['income_considered'] / 12 ),2) );?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3">Income assessment Program Recommended </td>
|
|
<td class="tdcenteralign" colspan="2"><?php echo $section5['income_assessment_program_recommended']?></td>
|
|
<td colspan="3" ><?php if( $master[0]['sales_pd_type'] == 2){ echo "Fixed Obligations (Rs Per annum)"; } else { echo "Fixed Obligations (Rs per month)"; } ?></td>
|
|
<td class="tdcenteralign" colspan="2"><?php echo $rupee_symbol.' '.MYUTIL::customIndianNumberFormat( $section5['fixed_obligations'] )?></td>
|
|
</tr>
|
|
</tbody></table>
|
|
|
|
<?php
|
|
if(isset($section6))
|
|
{
|
|
?>
|
|
|
|
<br>
|
|
<table class="scorecard_table">
|
|
<tbody>
|
|
<tr>
|
|
<th class="thlargefont" colspan="10"> Property Information</th></tr>
|
|
<?php foreach($section6 as $property_key => $property_value) {
|
|
|
|
echo '<tr><th colspan="10"> Property '.($property_key + 1).'</th></tr>';
|
|
//echo 'Property '. ($property_key + 1).'<br>';
|
|
?>
|
|
<tr>
|
|
<td colspan="1" >Property Address (With Landmark & PIN)</td>
|
|
<td class="tdcenteralign" colspan="9" ><?php echo $property_value['property_address']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="1" >Property Type</td>
|
|
<td class="tdcenteralign" colspan="4" ><?php echo $property_value['property_type']?></td>
|
|
<td colspan="1" >Occupancy Status</td>
|
|
<td class="tdcenteralign" colspan="4" ><?php echo $property_value['occupancy_status']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="1">Permitted Property Usage</td>
|
|
<td class="tdcenteralign" colspan="4" ><?php echo $property_value['permitted_property_usage']?></td>
|
|
<td colspan="1" >Actual Property Usage</td>
|
|
<td class="tdcenteralign" colspan="4"><?php echo $property_value['actual_property_usage']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="1" >Built-Up Area</td>
|
|
<td class="tdcenteralign" colspan="4" ><?php echo $property_value['built_up_area'] .' '.$property_value['built_up_area_uom']; ?></td>
|
|
<td colspan="1" >Approx Mkt. Val (Rs)</td>
|
|
<td class="tdcenteralign" colspan="4" ><?php echo $rupee_symbol.' '.MYUTIL::customIndianNumberFormat($property_value['approx_mkt_val'])?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="1" >Property Ownership Status (Enter the names of the Property Owner(s) and their relationships)</td>
|
|
<td class="tdcenteralign" colspan="9"><?php echo $property_value['Property_Ownership_Status']?></td>
|
|
</tr>
|
|
<?php
|
|
//echo '<br>';
|
|
}?>
|
|
</tbody>
|
|
</table>
|
|
<?php }
|
|
?>
|
|
<br>
|
|
|
|
<table class="scorecard_table2">
|
|
<tbody>
|
|
<tr>
|
|
<th class="thlargefont" colspan="10" >Final Remarks of Sales officer</th>
|
|
</tr>
|
|
|
|
<?php if($master[0]['sales_pd_type'] == 2){?>
|
|
<tr>
|
|
<td colspan="4" >Business activity seen during visit (Yes / No)</td>
|
|
<td class="tdcenteralign" ><?php echo $section7['business_activity_seen']?></td>
|
|
<td colspan="4" >Location of workplace suits the business (Yes/No)</td>
|
|
<td class="tdcenteralign" ><?php echo $section7['location_workplace_suits_business']?></td>
|
|
</tr>
|
|
<?php }?>
|
|
<tr>
|
|
<td colspan="4" >Overall Assessment (Positive / Negative)</td>
|
|
<td class="tdcenteralign" <?php if($section7['overall_assessment'] == 'Positive') { echo 'style="color:green;"';}else{ echo 'style="color:red;"';} ?> ><?php echo $section7['overall_assessment']?></td>
|
|
<td colspan="4" >Recommended ROI for the case</td>
|
|
<td class="tdcenteralign" ><?php echo $section7['recommended_roi'].' %'?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2" >Any Other remarks </td>
|
|
<td style="text-align: justify;" colspan="8" ><?php echo $section7['any_other_remarks']?></td>
|
|
</tr>
|
|
<?php if($master[0]['sales_pd_type'] == 2){?>
|
|
<tr>
|
|
<td colspan="4">Behaviour on call (Rude/Neutral/Good/Pleasant)</td>
|
|
<td colspan="6" class="tdcenteralign" ><?php echo $section7['behaviour_call']?></td>
|
|
</tr>
|
|
<?php }?>
|
|
</tbody>
|
|
</table>
|
|
<br><br>
|
|
|
|
<div id="page_break"></div>
|
|
<br><table class="scorecard_table"><tr><th class="thlargefont" colspan="10">Satellite Image of PD Location</th></tr></table><br>
|
|
<p><b>GPS Coordinates of location where PD Visit was done : <?php echo $geo_location ? $geo_location : '-'; ?></b></p>
|
|
<?php if($geo_location) { ?>
|
|
<!-- <img style="border:3px solid #0191ed;" src = "<?php echo 'data:image/gif;base64,'.$satellite_image[0]['img']; ?>" alt = "PD Visted Location Satellite Image " height="300px" width="630px"> -->
|
|
<img style="border:3px solid #0191ed;" src = "<?php echo $satellite_image; ?>" alt = "PD Visted Location Satellite Image " height="300px" width="630px">
|
|
<?php
|
|
}else{ echo '<p>Due to location access not provided by loan applicant Geo coordinates on photographs and Satellite image of PD location is not shown</p>';}
|
|
?>
|
|
<?php
|
|
$iter = 0;
|
|
$photo_names = array('selfie_with_person_met' => 'Selfie with person met','approach_to_pd_location' => 'Approach to pd location','name_board_seen' => 'Name board seen', 'stock_image' => 'Stock image','workplace_interior_image' => 'Workplace interior image','satellite1' => 'satellite');
|
|
if($master[0]['sales_pd_type'] == 2){ $photo_names['selfie_with_person_met'] = 'Selfie of the person contacted';}
|
|
//echo count($section9);die();
|
|
//print_r(array_keys($section9));die();
|
|
$tot_rows = ceil(count($section9) / 3);
|
|
|
|
// foreach ($section9 as $key => $value) {
|
|
// print_r($value).'<br>';
|
|
|
|
// }
|
|
// die();
|
|
if(count($section9))
|
|
{
|
|
echo '<div id="page_break"></div>';
|
|
echo '<table class="scorecard_table"><tr><th class="thlargefont" colspan="10">Photograph`s</th></tr></table><br><table ><tbody>';
|
|
|
|
$add_factor = 0;
|
|
for($row = 0;$row < $tot_rows; $row++)
|
|
{
|
|
echo '<tr>';
|
|
|
|
$from = $row == 0 ? $row : ($row+$add_factor);
|
|
$to = ($from + 2);
|
|
$add_factor = $add_factor + 2;
|
|
for($i = $from ; $i <= $to; $i++)
|
|
{
|
|
|
|
if(isset($section9[$i]))
|
|
{
|
|
|
|
echo '<td style="text-align:center;border:1px solid;"> <img src="'.$section9[$i]['img'].'" height = "200" width="200" alt="'.$section9[$i]['img_name'].'"/><br>'.$photo_names [ $section9[$i]['img_name'] ].'</td>';
|
|
}
|
|
|
|
//unset($p_key);
|
|
}
|
|
echo '</tr>';
|
|
}
|
|
echo '</tbody></table>';
|
|
}
|
|
?>
|
|
<br>
|
|
<br><br>
|
|
<table class="scorecard_table">
|
|
<tbody>
|
|
<tr>
|
|
<td colspan="3" >Name of Sales Team Member </td>
|
|
<td class="tdcenteralign" colspan="7" ><?php echo $section8['name_of_sales_team_member']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" >Designation of Sales Team Member </td>
|
|
<td class="tdcenteralign" colspan="7" ><?php echo $section8['designation']?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" >Employee ID </td>
|
|
<td class="tdcenteralign" colspan="7" ><?php echo $smc_emp_code?$smc_emp_code:"-"?></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="3" >Date of PD Visit </td>
|
|
<td class="tdcenteralign" colspan="7" ><?php echo $section8['date']?></td>
|
|
</tr>
|
|
<!-- <tr>
|
|
<td colspan="3">Signature of PD Officer </td>
|
|
<td colspan="7" ></td>
|
|
</tr> -->
|
|
|
|
</tbody>
|
|
</table>
|
|
|
|
|
|
|
|
|
|
</body>
|
|
</html>
|
|
|
|
|