student fees status changes done

This commit is contained in:
gandhimathi 2018-04-23 16:15:41 +05:30
parent 521cae5d4c
commit 17c4ab3c50

View File

@ -27,6 +27,8 @@ class Fees_status_model extends CI_Model
$this->db->where('STC.IsActive','1');
if($search['requestedBranch']!='All'){
$this->db->where('STC.BranchID',$search['requestedBranch']);
$this->db->where('US.BranchCode',$search['requestedBranch']);
$this->db->where('CU.BranchCode',$search['requestedBranch']);
}
if($search['MobileNumber']!=''){
$this->db->where('ST.MobileNumber',$search['MobileNumber']);
@ -78,6 +80,7 @@ class Fees_status_model extends CI_Model
* created by kms
* */
public function getStudentFeesStructure($student=null){
$this->db->distinct();
$this->db->select('CF.ID,CF.Sem_Year,CF.ProgramType,SFS.FeesID,SFS.CourseID,SFS.CourseFees,SFS.STFOrWR,SFS.Waiver,SFS.Others,SFS.RollNo,CU.PC,CU.TC,CU.DC,CU.MC,CU.OtherFees,SM.SessionName as SessionName,SM1.SessionName as ToSessionName,BA.BatchCode,BA.BatchName');
$this->db->from(STUDENTS_FEES_STATUS.' as SFS');
$this->db->join(SESSIONMASTER.' as SM', 'SM.SessionID = SFS.SessionName');
@ -662,11 +665,12 @@ class Fees_status_model extends CI_Model
* get university details
* created by kms
* */
public function getUniversityDetails()
public function getUniversityDetails($requestedBy=null,$requestedBranch=null)
{
$this->db->select('UniversityID,UniversityName');
$this->db->where('IsActive','1');
$this->db->order_by('UniversityID','ASC');
$this->db->where('BranchCode',$requestedBranch);
$this->db->order_by('CreatedOn','DESC');
$unviversityDetails = $this->db->get(UNIVERSITY);
if($unviversityDetails->result()){
@ -677,7 +681,7 @@ class Fees_status_model extends CI_Model
$university_array['universityID'] = $row->UniversityID;
$university_array['universityName'] = $row->UniversityName;
$university_array['courseDetails']= $this->getCourseDetails($row->UniversityID);
$university_array['courseDetails']= $this->getCourseDetails($row->UniversityID,$requestedBranch);
$result_array[]=$university_array;
}
$result_university['univerSityDetails']= $result_array;
@ -699,11 +703,12 @@ class Fees_status_model extends CI_Model
* @params university id
* created by kms
* */
public function getCourseDetails($universityID=null)
public function getCourseDetails($universityID=null,$requestedBranch=null)
{
$this->db->select('CourseID,CONCAT(CourseName, "(",CourseCode,")") AS CourseName');
$this->db->where('UniversityID',$universityID);
$this->db->where('IsActive','1');
$this->db->where('BranchCode',$requestedBranch);
$this->db->order_by('CourseID','ASC');
$courseDetails = $this->db->get(COURSE);
return $courseDetails->result();