PD PROCESS
This commit is contained in:
parent
88a2df3ff3
commit
ed987e9443
@ -87,7 +87,7 @@ defined('EXIT__AUTO_MAX') OR define('EXIT__AUTO_MAX', 125); // highest auto
|
||||
// define login route name for token verification
|
||||
//defined('ROUTE_LOGIN') OR define('ROUTE_LOGIN', '(listLessPDDetails/:any)'); // no errors
|
||||
//defined('ROUTE_LOGIN') OR define('ROUTE_LOGIN', '(listAllTemplates/:any)'); // no errors
|
||||
defined('ROUTE_LOGIN') OR define('ROUTE_LOGIN', 'getListPDOfficers'); // no errors
|
||||
defined('ROUTE_LOGIN') OR define('ROUTE_LOGIN', 'getVendorCityMap'); // no errors
|
||||
|
||||
/*********************AWS resources Constants*************************************************/
|
||||
defined('PROFILE_PICTURE_BUCKET_NAME') OR define('PROFILE_PICTURE_BUCKET_NAME','sineedgedevprofilepic');
|
||||
|
||||
@ -447,29 +447,29 @@ class Entity_Management_Controller extends REST_Controller {
|
||||
$count = 0;
|
||||
$records = $this->post('records');
|
||||
|
||||
foreach($records as $key => $record)
|
||||
{
|
||||
// foreach($records as $key => $record)
|
||||
// {
|
||||
|
||||
if($record['vendor_city_map_id'] != null || $record['vendor_city_map_id'] != "")
|
||||
if($records['vendor_city_map_id'] != null || $records['vendor_city_map_id'] != "")
|
||||
{
|
||||
|
||||
$where_condition_array = array('vendor_city_map_id' => $record['vendor_city_map_id']);
|
||||
$vendor_city_map_id = $this->Entity_Management_Model->updateRecords($record,VENDORCITYMAP,$where_condition_array);
|
||||
$where_condition_array = array('vendor_city_map_id' => $records['vendor_city_map_id']);
|
||||
$vendor_city_map_id = $this->Entity_Management_Model->updateRecords($records,VENDORCITYMAP,$where_condition_array);
|
||||
if($vendor_city_map_id != "" || $vendor_city_map_id != null){ $count++; }
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
$vendor_city_map_id = $this->Entity_Management_Model->saveRecords($record,VENDORCITYMAP);
|
||||
$vendor_city_map_id = $this->Entity_Management_Model->saveRecords($records,VENDORCITYMAP);
|
||||
if($vendor_city_map_id != "" || $vendor_city_map_id != null){ $count++; }
|
||||
}
|
||||
}
|
||||
// }
|
||||
|
||||
if(count($records) == $count)
|
||||
if($vendor_city_map_id != "" || $vendor_city_map_id != null)
|
||||
{
|
||||
$data['dataStatus'] = true;
|
||||
$data['status'] = REST_Controller::HTTP_OK;
|
||||
$data['records'] = true;
|
||||
$data['records'] = $vendor_city_map_id;
|
||||
$this->response($data,REST_Controller::HTTP_OK);
|
||||
}
|
||||
else
|
||||
|
||||
@ -1071,9 +1071,9 @@ class PD_Controller extends REST_Controller {
|
||||
$pd_detail_answer_id = "";
|
||||
$image_count = "";
|
||||
$answer_count = "";
|
||||
$image_array = array();
|
||||
$images_array = array();
|
||||
$answers_array = array();
|
||||
//print_r($records);
|
||||
//print_r($records); - text,options,checkbox
|
||||
foreach($records as $record_key => $record)
|
||||
{
|
||||
if($record['pd_detail_id'] != "" || $record['pd_detail_id'] != null)
|
||||
@ -1113,6 +1113,7 @@ class PD_Controller extends REST_Controller {
|
||||
|
||||
|
||||
//IMAGES SAVE - pd_document_id, fk_pd_id, fk_pd_detail_id, pd_document_title, pd_document_name, createdon, fk_createdby, updatedon, fk_updatedby
|
||||
|
||||
foreach($images_array as $image_key => $image)
|
||||
{
|
||||
|
||||
@ -1158,7 +1159,7 @@ class PD_Controller extends REST_Controller {
|
||||
|
||||
}
|
||||
|
||||
if(($pd_detail_id != "" || $pd_detail_id != null) && count($images_array) == $image_count && count($answers) == $answer_count)
|
||||
if(($pd_detail_id != "" || $pd_detail_id != null) && count($images_array) == $image_count && count($answers_array) == $answer_count)
|
||||
{
|
||||
|
||||
$data['dataStatus'] = true;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user