From f08922e3d635a601099bb99cff0a32afee4c0c2e Mon Sep 17 00:00:00 2001 From: VE10-Sanjeev Date: Wed, 17 May 2023 14:21:40 +0530 Subject: [PATCH] 3rd time SMC Archived : ps --- api/application/models/PD_Model.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/api/application/models/PD_Model.php b/api/application/models/PD_Model.php index ca79e1cc..2088143d 100644 --- a/api/application/models/PD_Model.php +++ b/api/application/models/PD_Model.php @@ -355,9 +355,14 @@ class PD_Model extends SPARQ_Model { { $current_smc_lender_id = ENVIRONMENT == 'production' ? 7 : 35; //pk id of SMC in live and demo $this->db->WHERE('PDTRIGGER.fk_lender_id',$current_smc_lender_id); - $this->db->WHERE('PDTRIGGER.pd_status !=',ARCHIVED); } + if(ENVIRONMENT == 'production' && $pd_lender == 7){ + $this->db->WHERE('PDTRIGGER.pd_status !=',ARCHIVED); + }else if(ENVIRONMENT != 'production' && $pd_lender == 35){ + $this->db->WHERE('PDTRIGGER.pd_status !=',ARCHIVED); + } + $this->db->ORDER_BY('PDTRIGGER.pd_id','DESC'); $this->db->LIMIT($limit,0);