diff --git a/Apollo/api/application/config/constants.php b/Apollo/api/application/config/constants.php index 0ec317d1..3e81960a 100755 --- a/Apollo/api/application/config/constants.php +++ b/Apollo/api/application/config/constants.php @@ -153,13 +153,8 @@ defined('SESSIONSCHEDULEDETAILS') OR define('SESSIONSCHEDULEDETAILS','T_SessionS defined('STUDENTDOCUMENTDETAILS') OR define('STUDENTDOCUMENTDETAILS','T_StudentDocumentsDetails'); defined('STUDENTDOCUMENTTRACKDETAILS') OR define('STUDENTDOCUMENTTRACKDETAILS','T_Student_DocumentTrack_Details'); -// branch relation db tables - -defined('UNIVERSITYBRANCHREL') OR define('UNIVERSITYBRANCHREL','T_Univ_Branch_Rel'); -defined('COURSEBRANCHREL') OR define('COURSEBRANCHREL','T_Course_Branch_Rel'); -defined('STATUSBRANCHREL') OR define('STATUSBRANCHREL','T_Status_Branch_Rel'); -defined('INOUTCOMEBRANCHREL') OR define('INOUTCOMEBRANCHREL','T_Income_Outcome_Branch_Rel'); -defined('CENTERBRANCHREL') OR define('CENTERBRANCHREL','T_Center_Branch_Rel'); +// define APPLICATION certificate type constant +defined('APPLICATION_CONST') OR define('APPLICATION_CONST','APPLICATION'); diff --git a/Apollo/api/application/controllers/Fees_Status_Controller.php b/Apollo/api/application/controllers/Fees_Status_Controller.php index 782a3037..22ca5714 100755 --- a/Apollo/api/application/controllers/Fees_Status_Controller.php +++ b/Apollo/api/application/controllers/Fees_Status_Controller.php @@ -144,7 +144,7 @@ class Fees_Status_Controller extends REST_Controller { $detailsChild['CreatedBy'] = $this->post('createdBy'); $detailsChild['CreatedOn'] = $now->format('Y-m-d H:i:s'); $detailsChild['UpdatedBy'] = $this->post('requestedBranch'); - $updateDetails = $this->Fees_model->updateFees($detailsChild,$this->post('courseID'));// Check if the users data store contains users (in case the database result returns NULL) + $updateDetails = $this->Fees_model->updateFees($detailsChild,$this->post('courseID'),$this->post('feesName'));// Check if the users data store contains users (in case the database result returns NULL) if ($updateDetails) { $updateDetails['status'] = REST_Controller::HTTP_OK; diff --git a/Apollo/api/application/models/Fees_status_model.php b/Apollo/api/application/models/Fees_status_model.php index 67a82e08..b5fbd1b2 100755 --- a/Apollo/api/application/models/Fees_status_model.php +++ b/Apollo/api/application/models/Fees_status_model.php @@ -424,7 +424,7 @@ class Fees_status_model extends CI_Model * created by kms * */ - public function updateFees($feesPaidDetails=null,$courseID=null) + public function updateFees($feesPaidDetails=null,$courseID=null,$feesName=null) { if($feesPaidDetails['UpdatedBy']=='All'){ $this->db->select('BranchID'); @@ -478,7 +478,7 @@ class Fees_status_model extends CI_Model if($feesPaidDetails['BillAmount']!='0'){ - $dayBookEntry = $this->insertDayBookMaster($feesPaidDetails,$feesPayedID); + $dayBookEntry = $this->insertDayBookMaster($feesPaidDetails,$feesPayedID,$courseID,$feesName); } // Entry for all status screen except fees @@ -1142,7 +1142,7 @@ class Fees_status_model extends CI_Model * insert day book master while fees update * created by kms * */ - public function insertDayBookMaster($data=null,$paymentID){ + public function insertDayBookMaster($data=null,$paymentID,$courseID,$feesName){ $this->db->select('Firstname'); $this->db->where('StudentID', $data['StudentID']); $getStudentName=$this->db->get(STUDENTS)->result(); @@ -1161,6 +1161,9 @@ class Fees_status_model extends CI_Model $insertArray['PaidTo'] = $getStudentName[0]->Firstname; $insertArray['BranchCode'] = $data['UpdatedBy']; $insertArray['ModeOfPayment'] = $data['ModeOfPayment']; + $insertArray['StudentID'] = $data['StudentID']; + $insertArray['CourseID'] = $courseID; + $insertArray['FeePaymentDetails'] = $feesName; $this->db->select('ID,TypeID'); $this->db->where('TypeID', 'I002'); @@ -1189,6 +1192,9 @@ class Fees_status_model extends CI_Model $expenseArray['PaidTo'] = $getStudentName[0]->Firstname; $expenseArray['BranchCode'] = $data['UpdatedBy']; $expenseArray['ModeOfPayment'] = $data['ModeOfPayment']; + $expenseArray['StudentID'] = $data['StudentID']; + $expenseArray['CourseID'] = $courseID; + $expenseArray['FeePaymentDetails'] = $feesName; $this->db->select('ID,TypeID'); $this->db->where('TypeID', 'I001'); $this->db->where('TypeName', 'FEES'); diff --git a/Apollo/api/application/models/Studentview_model.php b/Apollo/api/application/models/Studentview_model.php index 4dfa717f..2072dba1 100755 --- a/Apollo/api/application/models/Studentview_model.php +++ b/Apollo/api/application/models/Studentview_model.php @@ -28,7 +28,7 @@ class Studentview_model extends CI_Model $result['studentStatus'] = true; $result['studentDetails'] = $studentDetails; // get student course details - $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID); + $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID,$requestFrom); } else{ $result['studentStatus'] = false; @@ -45,7 +45,7 @@ class Studentview_model extends CI_Model $result['studentStatus'] = true; $result['studentDetails'] = $studentDetails; // get student course details - $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID); + $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID,$requestFrom); } else{ $result['studentStatus'] = false; @@ -62,7 +62,7 @@ class Studentview_model extends CI_Model $result['studentStatus'] = true; $result['studentDetails'] = $studentDetails; // get student course details - $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID); + $result['courseDetails'] = $this->getStudentCourse($studentDetails->StudentID,$requestFrom); } else{ $result['studentStatus'] = false; @@ -77,7 +77,7 @@ class Studentview_model extends CI_Model * get student course details * created by kms * */ - public function getStudentCourse($studentId=null){ + public function getStudentCourse($studentId=null,$requestFrom=null){ $this->db->select('SCU.EnrollmentID,CU.CourseID,CU.CourseName,US.UniversityID,US.UniversityName,US.UniversityShortName'); $this->db->from( STUDENTCOURSE . ' as SCU'); @@ -101,7 +101,14 @@ class Studentview_model extends CI_Model // get student boollet details $fetchData['studyMaterialDetails']=$this->getStudentMaterialDetails($studentId,$row->CourseID); // get application details - $fetchData['applicationDetails']=$this->getStudentCertificateDetails($studentId,$row->CourseID); + if($requestFrom!='2'){ + $fetchData['applicationDetails']=$this->getStudentApplicationDetails($studentId,$row->CourseID); + $fetchData['answerbookletDetails']=$this->getStudentAnswerbookletDetails($studentId,$row->CourseID); + + + } + $fetchData['certificateDetails']=$this->getStudentCertificateDetails($studentId,$row->CourseID); + // get student Mark crad details $fetchData['markCardDetails']=$this->getMarkcardDetails($studentId,$row->CourseID); @@ -332,6 +339,33 @@ class Studentview_model extends CI_Model $this->db->join(PICK_LIST_DETAILS.' as PLD', 'PLD.ListCode = AS.ListCode'); $this->db->where('CU.CourseID', $courseID); $this->db->where('AS.StudentID', $studentID); + $this->db->where('CM.CertificateName !=', APPLICATION_CONST); + $this->db->order_by('AS.ID', 'DESC'); + $getCertDetails = $this->db->get(); + + if($getCertDetails->result()){ + return $getCertDetails->result(); + } + + else { + return false; + } + + } + /* + * get student applications details + * created by kms + * */ + public function getStudentApplicationDetails($studentID=null,$courseID=null){ + $this->db->select('AS.CertificationNo,AS.AppDate,AS.Comments,CM.CertificateName,PLD.ListName'); + $this->db->from(APPLICATION_STATUS.' as AS'); + $this->db->join(CERTIFICATION_MASTER.' as CM','CM.CertificationID = AS.CertificationType'); + //$this->db->join(COURSE_FEES.' as CF','CF.ID = AS.CourseID'); + $this->db->join(COURSE.' as CU', 'CU.CourseID = AS.CourseID'); + $this->db->join(PICK_LIST_DETAILS.' as PLD', 'PLD.ListCode = AS.ListCode'); + $this->db->where('CU.CourseID', $courseID); + $this->db->where('AS.StudentID', $studentID); + $this->db->where('CM.CertificateName', APPLICATION_CONST); $this->db->order_by('AS.ID', 'DESC'); $getCertDetails = $this->db->get(); @@ -368,23 +402,25 @@ class Studentview_model extends CI_Model } } /* - * get student application details - * created by kms*/ - public function getStudentApplicationDetails($studentID=null,$courseID=null){ - $this->db->select('AS.CourseID,AS.AppDate,AS.Comments,CF.Sem_Year,PLD.ListName'); - $this->db->from(APPLICATION_STATUS.' as AS'); - $this->db->join(COURSE_FEES.' as CF','CF.ID = AS.CourseID'); + * get student answer booklet details + * created by kms + * */ + public function getStudentAnswerbookletDetails($studentID=null,$courseID=null){ + $this->db->select('ABT.CourseID,ABT.AnsDate,ABT.Comments,CF.Sem_Year,CF.FeesType,ABT.Sem,PLD.ListName'); + $this->db->from(ANSWER_BOOKLET.' as ABT'); + $this->db->join(COURSE_FEES.' as CF','CF.ID = ABT.CourseID'); $this->db->join(COURSE.' as CU', 'CU.CourseID = CF.CourseID'); - $this->db->join(PICK_LIST_DETAILS.' as PLD', 'PLD.ListCode = AS.ListCode'); + $this->db->join(PICK_LIST_DETAILS.' as PLD', 'PLD.ListCode = ABT.ListCode'); $this->db->where('CU.CourseID', $courseID); - $this->db->where('AS.StudentID', $studentID); - $this->db->order_by('AS.ID', 'DESC'); - $getAppDetails = $this->db->get(); - if ($getAppDetails->result()){ - return $getAppDetails->result(); + $this->db->where('ABT.StudentID', $studentID); + $this->db->order_by('ABT.ID', 'DESC'); + $getBookletDetails = $this->db->get(); + if ($getBookletDetails->result()){ + return $getBookletDetails->result(); } else{ return false; } } + } \ No newline at end of file diff --git a/Apollo/assets/js/controllers/feesStatusCtrl.js b/Apollo/assets/js/controllers/feesStatusCtrl.js index 754adbfc..6a4210ba 100755 --- a/Apollo/assets/js/controllers/feesStatusCtrl.js +++ b/Apollo/assets/js/controllers/feesStatusCtrl.js @@ -457,6 +457,7 @@ app.controller('feesStatusCtrl', ["$scope","$rootScope","toaster", "$filter", "n courseID:myModel.CourseID, courseAmount:updateModel.feesType.ActualFees, feesID: updateModel.feesType.FeesID, + feesName: updateModel.feesType.Sem_Year, billNO: updateModel.billNo, billDate: $scope.billDate, billAmount:updateModel.billAmount, diff --git a/Apollo/assets/views/student/studentDetailsModal.html b/Apollo/assets/views/student/studentDetailsModal.html index d8c98578..cb5e3927 100755 --- a/Apollo/assets/views/student/studentDetailsModal.html +++ b/Apollo/assets/views/student/studentDetailsModal.html @@ -298,8 +298,7 @@ - - +
+ +
+ + +
+
+ +
+ + + + + + + + + + + + + + + + + + + + + + +
Sem/YearStatusDateComments
+ {{booklet.Sem}} + + {{booklet.ListName}} + + {{booklet.AnsDate}} + + {{booklet.Comments}} +
+ + + +
+
+ + + +
+
+ +
+ + + + + + + + + + + + + diff --git a/Apollo/assets/views/student/studentView.html b/Apollo/assets/views/student/studentView.html index 29686a80..5075e7c6 100755 --- a/Apollo/assets/views/student/studentView.html +++ b/Apollo/assets/views/student/studentView.html @@ -457,12 +457,12 @@
-
+
-
Document NameStatusDateComments
+
@@ -474,7 +474,7 @@ - +