From eff36cb2feefc4a07f4447fc2d72b3cc8e47f63a Mon Sep 17 00:00:00 2001 From: velz Date: Thu, 8 Nov 2018 20:15:50 +0530 Subject: [PATCH] GET PD FORM MODIFIED --- api/application/config/constants.php | 2 +- api/application/controllers/PD_Controller.php | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/api/application/config/constants.php b/api/application/config/constants.php index 07a9a749..613278f8 100644 --- a/api/application/config/constants.php +++ b/api/application/config/constants.php @@ -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', 'loadFullTemplate'); // no errors +defined('ROUTE_LOGIN') OR define('ROUTE_LOGIN', 'getPDFormDetails'); // no errors /*********************AWS resources Constants*************************************************/ defined('PROFILE_PICTURE_BUCKET_NAME') OR define('PROFILE_PICTURE_BUCKET_NAME','sineedgedevprofilepic'); diff --git a/api/application/controllers/PD_Controller.php b/api/application/controllers/PD_Controller.php index 70c6aff4..a526b157 100644 --- a/api/application/controllers/PD_Controller.php +++ b/api/application/controllers/PD_Controller.php @@ -1512,12 +1512,12 @@ class PD_Controller extends REST_Controller { { if($result['iter_sub_column_name'] == "" || $result['iter_sub_column_name'] == null) { - if($result['iter_column_name'] != $pre_group && $result['iteration'] != $pre_iter) + if($result['iter_column_name'] != $pre_group)// && $result['iteration'] != $pre_iter) { $t1 = array(); $group = array(); - // echo "New-".$result['iter_column_name']; + //echo "New-".$result['iter_column_name']; // print_r(array($result['column_name']=>$result['column_value'])); $t1 = array_merge($t1,array($result['column_name']=>$result['column_value'])); $group[$result['iter_column_name']][$result['iteration']] = $t1; @@ -1571,7 +1571,7 @@ class PD_Controller extends REST_Controller { } - + //print_r($group); $final_data = array_merge($final_data,$group); } //print_r($sub_group); @@ -1580,6 +1580,7 @@ class PD_Controller extends REST_Controller { $i = 0; if(count($sub_group)) { + foreach($sub_group as $key => $value) { //echo $key;