From 64f2951f1fcb982e582fdbf238170683f67c06b4 Mon Sep 17 00:00:00 2001 From: velz Date: Tue, 12 Jun 2018 13:35:17 +0530 Subject: [PATCH] Regards issue 1156 --- Apollo/api/application/models/Hallticket_model.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Apollo/api/application/models/Hallticket_model.php b/Apollo/api/application/models/Hallticket_model.php index 63235bf0..ab0f3740 100755 --- a/Apollo/api/application/models/Hallticket_model.php +++ b/Apollo/api/application/models/Hallticket_model.php @@ -665,12 +665,12 @@ class Hallticket_model extends CI_Model public function getBatchDetails($UniversityID,$branchId) { - $this->db->select('BatchID,BatchCode,BatchName'); + $this->db->select("BatchID,BatchCode,BatchName,str_to_date( BatchDate,'%d-%m-%Y') as BD"); $this->db->from('T_BatchMaster'); $this->db->where('UniversityID',$UniversityID); $this->db->where('IsActive',1); $this->db->where('BranchCode',$branchId); - $this->db->order_by('BatchID','DESC'); + $this->db->order_by("BD","DESC"); $res = $this->db->get(); return $res->result();