SMC SAPLED TYPE 7,8 REVOKED
This commit is contained in:
parent
2df3cff689
commit
6cd6e98058
@ -256,5 +256,6 @@ $route['(getRawData/:any)'] = 'Data_Dump_Controller/getRawData';
|
||||
$route['loadSalesPDTemplate'] = 'Sales_PD_Controller/loadSalesPDTemplate';
|
||||
$route['saveSalesPD'] = 'Sales_PD_Controller/saveSalesPD';
|
||||
$route['(downloadSalesPDReport/:any)'] = 'Sales_PD_Controller/getSalesPDReport';
|
||||
$route['(listSalesPD/:any/:any)'] = 'Sales_PD_Controller/listSalesPD';
|
||||
$route['listSalesPD/(:any)'] = 'Sales_PD_Controller/listSalesPD';
|
||||
$route['listSalesPD/(:any)/(:any)'] = 'Sales_PD_Controller/listSalesPD';
|
||||
|
||||
|
||||
@ -4899,7 +4899,7 @@ public function getPDFormDetailsJSON_post()
|
||||
{
|
||||
$temp_dir_name = isset($form_name[ $image['fk_form_id'] ]) ? $form_name[ $image['fk_form_id'] ] : 'Common';
|
||||
|
||||
$this->zip->add_data('pdimages/'.$temp_dir_name.'/'.$image['pd_document_name'],file_get_contents($image['doc_url']));
|
||||
$this->zip->add_data('pdimages/'.$image['pd_document_name'],file_get_contents($image['doc_url']));
|
||||
}
|
||||
|
||||
$temp_path = $main_applicant_name.'_'.$pdid.'_'.'pd_images.zip';
|
||||
|
||||
@ -56,7 +56,7 @@ class Sales_PD_Controller extends REST_Controller {
|
||||
$applicant_id = '';
|
||||
$officer = '';
|
||||
|
||||
foreach ($records['pd_json'] as $key => $value)
|
||||
foreach (json_decode($records['pd_json']) as $key => $value)
|
||||
{
|
||||
//print_r($value);die();
|
||||
if($value['section_id'] == 1)
|
||||
@ -161,10 +161,11 @@ class Sales_PD_Controller extends REST_Controller {
|
||||
$view_data['section'.$section['section_id'] ] = $this->processSalesPDJSON($section);
|
||||
}
|
||||
|
||||
//print_r($view_data);die();
|
||||
//$view_name = $sales_pd_data[0]['short_name'].'_'.$sales_pd_data[0]['abbr'];
|
||||
$view_name = $sales_pd_data[0]['short_name'];
|
||||
$html_content = $this->load->view('sale_pd_templates/'.$view_name,$view_data,true);
|
||||
//echo $html_content;die();
|
||||
echo $html_content;die();
|
||||
$pdf_doc = $this->pdfgenerator->generate($html_content, $filename='version', $stream=false, $paper = 'A4', $orientation = "portrait");
|
||||
//End of PDF Gen using DOM PDF
|
||||
$output_file = $this->external_path ."/sales_pd/" . $sales_pd_id . "/temp.pdf";
|
||||
@ -222,7 +223,7 @@ class Sales_PD_Controller extends REST_Controller {
|
||||
$where_condition_array = array('SALES_PD_DATA.createdby' => $user_id);
|
||||
}
|
||||
$order_by = 'SALES_PD_DATA.sales_pd_id';
|
||||
$sales_pd_data = $this->Sales_PD_Model->getJoinRecords($columns,$table,$joins,$where_condition_array);
|
||||
$sales_pd_data = $this->Sales_PD_Model->getJoinRecords($columns,$table,$joins,$where_condition_array,$order_by,'DESC');
|
||||
if(count($sales_pd_data))
|
||||
{
|
||||
$data['dataStatus'] = true;
|
||||
|
||||
@ -93,7 +93,7 @@ class SPARQ_Model extends CI_Model {
|
||||
|
||||
}
|
||||
|
||||
public function getJoinRecords($columns,$table,$joins,$where_condition_array = array(),$order_by = '',$print_query = '')
|
||||
public function getJoinRecords($columns,$table,$joins,$where_condition_array = array(),$order_by_cloumn = '',$order_by = 'ASC',$print_query = '')
|
||||
{
|
||||
|
||||
|
||||
@ -115,7 +115,7 @@ class SPARQ_Model extends CI_Model {
|
||||
|
||||
if($order_by != '')
|
||||
{
|
||||
$this->db->ORDER_BY($order_by);
|
||||
$this->db->ORDER_BY($order_by_cloumn,$order_by);
|
||||
}
|
||||
|
||||
$data = $this->db->get()->result_array();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user