From 22afde7cb21af94cc84f7f9e0392472736fa92e6 Mon Sep 17 00:00:00 2001 From: dineshkumarkannan Date: Mon, 10 Sep 2018 17:19:25 +0530 Subject: [PATCH 1/9] fee id capture details changes : kdk --- ...Receive_Enrolment_Fees_Univ_Controller.php | 4 ++- .../Receive_Enrolment_Fees_Univ_model.php | 9 ++++--- .../studentUnivFormIdFeeDetailsCtrl.js | 17 +++++++----- .../student/studentUnivFormIdFeeDetails.html | 26 ++++++++++++------- 4 files changed, 36 insertions(+), 20 deletions(-) diff --git a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php index 01120c37..292a6783 100644 --- a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php +++ b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php @@ -277,7 +277,9 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller { // kdk public function getForFormIdDraftDetails_post(){ $reqBranch = $this->post('localDetails'); - $getForFormIdDraftDetails = $this->receive_model->getForFormIdDraftDetails(); // Check if the employee exist + $getDetailsFor = $this->post('getDetailsFor'); + + $getForFormIdDraftDetails = $this->receive_model->getForFormIdDraftDetails($getDetailsFor); // Check if the employee exist if ($getForFormIdDraftDetails) { $getForFormIdDraftDetails['status'] = REST_Controller::HTTP_OK; // Set the response and exit diff --git a/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php b/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php index e4c23cf8..fe1ecb5b 100644 --- a/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php +++ b/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php @@ -893,8 +893,10 @@ class Receive_Enrolment_Fees_Univ_model extends CI_Model { // get formid draft mode list details // kdk - public function getForFormIdDraftDetails(){ - $selectQuery = "SELECT * FROM T_FormId_FeeDetails_Received_From_University WHERE DraftStatus = 1"; + public function getForFormIdDraftDetails($getUnivDetails){ + $selectUniv = $getUnivDetails['univCode']; + + $selectQuery = "SELECT * FROM T_FormId_FeeDetails_Received_From_University WHERE UniversityID = '$selectUniv' AND DraftStatus = 1"; $details = $this->db->query($selectQuery); $detailsList = $details->result(); if($detailsList) { @@ -1100,7 +1102,8 @@ $result['updatedraftStatus'] = false; $this->db->select('FUD.*, concat(ST.FirstName," ", ST.Lastname) as app_StudentName, IF(concat(ST.FirstName," " , ST.Lastname) = FUD.Student_Name, "YES", "NO") as StudentNameStatus , ST.Fathername as app_FatherName, IF(ST.Fathername = FUD.Father_Name, "YES", "NO") as FathernameStatus, - CM.CourseCode as app_CourseCode, IF(CM.CourseCode = FUD.CourseCode, "YES", "NO" ) as CourseCodeStatus'); + CM.CourseCode as app_CourseCode, IF(CM.CourseCode = FUD.CourseCode, "YES", "NO" ) as CourseCodeStatus, + IF(ENU.SemesterYear = FUD.Semester, "YES", "NO" ) as SemesterStatus'); $this->db->from('T_FormId_FeeDetails_Received_From_University as FUD'); $this->db->join(ENROLMENTRECEIVEDFROMUNIV.' as ENU', 'FUD.FormID = ENU.FormID' ); $this->db->join(STUDENTCOURSE.' as STC', 'STC.EnrollmentID = ENU.EnrolmentNo'); diff --git a/Apollo/assets/js/controllers/studentUnivFormIdFeeDetailsCtrl.js b/Apollo/assets/js/controllers/studentUnivFormIdFeeDetailsCtrl.js index 24c39d90..5f728c94 100644 --- a/Apollo/assets/js/controllers/studentUnivFormIdFeeDetailsCtrl.js +++ b/Apollo/assets/js/controllers/studentUnivFormIdFeeDetailsCtrl.js @@ -129,9 +129,10 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter $scope.Searchloader = false; $scope.studentData = false; - + $scope.formIdListNoRecordFound = false; $scope.onSubmit = function () { $scope.Searchloader = true; + $scope.formIdListNoRecordFound = false; if ($scope.searchData.University !== '' && $scope.searchData.Course !== '') { $scope.Searchloader = true; var empListreq = { @@ -151,11 +152,13 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter $scope.studentData = true; $scope.data = response.data.studentFeeCompareDetails; $scope.studentListLength = $scope.data.length; + $scope.formIdListNoRecordFound = false; // $scope.statusMessage = $scope.data.message; } else { + $scope.formIdListNoRecordFound = true; $scope.Searchloader = false; $scope.studentData = false; - $scope.statusMessage = $scope.data.message; + $scope.statusMessage = response.data.message; } }); } else { @@ -169,9 +172,8 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter } $scope.myObjErr = { - "text-decoration": "underline", - "text-decoration-color": "red", - "font-size": "inherit" + "color": "red", + "font-size": "inherit", } $scope.editId = -1; @@ -334,6 +336,7 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter // get subtab details for the formid fee details get form the university $scope.subTabActive = function (tab) { + $scope.subTabactive = tab; if (tab == 'subTabactive2') { getDraftFormIdDetails(); } @@ -369,6 +372,7 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter } + $scope.draftListDetails = ''; $scope.draftListDetailsNoRecordFound = false; $scope.draftListDetailsLoading = false; @@ -384,7 +388,8 @@ app.controller('studentUnivFormIdFeeDetailsCtrl', ["$scope", "toaster", "$filter 'Content-Type': 'application/json' }, data: { - localDetails: localDetail + localDetails: localDetail, + getDetailsFor: $scope.formUploadUnivSelectID } }; $http(getFormIdDraftDetailsList).then(function (response) { diff --git a/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html b/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html index 7072f594..5a0ffe4d 100644 --- a/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html +++ b/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html @@ -101,6 +101,9 @@

{{statusMessage}}

+
+
No Record Found ...
+
@@ -181,16 +184,16 @@ {{p.Year}} - - - @@ -312,7 +315,7 @@ - @@ -321,7 +324,7 @@ - +
@@ -336,7 +339,7 @@
- +
@@ -417,6 +420,9 @@ Loading...
+
+
No Record Found ...
+
- {{p.Semester}} +
{{p.Semester}}
- {{p.Student_Name}} + +
{{p.Student_Name}}
- {{p.Father_Name}} + +
{{p.Father_Name}}
- {{p.CourseCode}} + +
{{p.CourseCode}}
{{p.ActualCourseFee}} {{p.CourseFee}}
From 2cbb4d7ffa988767a6925e97fb9b129c3a765d4c Mon Sep 17 00:00:00 2001 From: gandhimathi Date: Mon, 10 Sep 2018 17:23:37 +0530 Subject: [PATCH 2/9] edit university payment details changes --- Apollo/api/application/config/routes.php | 2 + ...Receive_Enrolment_Fees_Univ_Controller.php | 37 ++++ .../Receive_Enrolment_Fees_Univ_model.php | 75 +++++++- .../js/controllers/univFormPaymentCtrl.js | 166 ++++++++++++++++++ .../views/student/UnivFormPaymentDetails.html | 9 +- .../student/updateUniversityPaymentModal.html | 103 +++++++++++ 6 files changed, 390 insertions(+), 2 deletions(-) create mode 100644 Apollo/assets/views/student/updateUniversityPaymentModal.html diff --git a/Apollo/api/application/config/routes.php b/Apollo/api/application/config/routes.php index 0465bb22..472986f4 100755 --- a/Apollo/api/application/config/routes.php +++ b/Apollo/api/application/config/routes.php @@ -379,4 +379,6 @@ $route['getUniversityCodeForFormDetailsGet'] = 'Receive_Enrolment_Fees_Univ_Cont $route['getUnmatchedFormIdFeesDetails'] = 'Receive_Enrolment_Fees_Univ_Controller/getUnmatchedFormIdFeesDetails'; $route['addToAccountStateList'] = 'Receive_Enrolment_Fees_Univ_Controller/addToAccountStateList'; $route['addUniversityPaymentDetails'] = 'Receive_Enrolment_Fees_Univ_Controller/addUniversityPaymentDetails'; +$route['updateUniversityPaymentDetails'] = 'Receive_Enrolment_Fees_Univ_Controller/updateUniversityPaymentDetails'; + diff --git a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php index 01120c37..8cff220d 100644 --- a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php +++ b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php @@ -38,6 +38,7 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller { $this->methods['addManualEnrolmentDetails_post']['limit'] = 1000; $this->methods['addUniversityPaymentDetails_post']['limit'] = 1000; + $this->methods['updateUniversityPaymentDetails_post']['limit'] = 1000; // load the model $this->load->model('Receive_Enrolment_Fees_Univ_model', 'receive_model'); @@ -517,6 +518,42 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller { } } + /* + * update university payment details*/ + public function updateUniversityPaymentDetails_post(){ + $now = new DateTime(); + $now->setTimezone(new DateTimezone('Asia/Kolkata')); + $details=$this->post('details'); + $localData=$this->post('localDetails'); + $update['ID']=$details['ID']; + $update['PaymentID']=$details['paymentID']; + $payment['BillNo']=$details['billNo']; + $payment['ReceiptNo']=$details['receiptNo']; + $payment['Amount']=$details['billAmount']; + $payment['ApprovedDate']=$details['date']; + $payment['Remarks']=$details['comments']; + $payment['BranchCode']=$localData['localBranchID']; + $payment['updatedBy']=$localData['localUserID']; + $payment['updatedOn']=$now->format('Y-m-d H:i:s'); + // debit array + $debit['DebitAmount']=$details['billAmount']; + $debit['ApprovedDate']=$details['date']; + $debit['BranchCode']=$localData['localBranchID']; + $debit['updatedBy']=$localData['localUserID']; + $debit['updatedOn']=$now->format('Y-m-d H:i:s'); + $updatePaymentDetails=$this->receive_model->updatePaymentDetails($update,$payment,$debit); + if($updatePaymentDetails['status']==true){ + $this->response($updatePaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code + } + else if($updatePaymentDetails['status']==false){ + $this->response($updatePaymentDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code + + } + else{ + $this->response(['message' => 'Try again', 'status' => false], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code + + } + } } \ No newline at end of file diff --git a/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php b/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php index e4c23cf8..4a5584d9 100644 --- a/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php +++ b/Apollo/api/application/models/Receive_Enrolment_Fees_Univ_model.php @@ -1352,7 +1352,7 @@ $result['updatedraftStatus'] = false; * created by kms * */ public function getPaymentVerificationDetails($search){ - $this->db->select('UNCD.ID,UNCD.FormMapID,UNCD.PaymentMapID,UNCD.FormID,UNCD.CreditAmount,UNCD.DebitAmount,UNCD.ApprovedDate,UNCD.UniversityCode,UNCD.UniversityName,UNCD.TypeID,ENU.EnrolmentNo,UNP.BillNo,UNP.PID as PaymentID'); + $this->db->select('UNCD.ID,UNCD.FormMapID,UNCD.PaymentMapID,UNCD.FormID,UNCD.CreditAmount,UNCD.DebitAmount,DATE_FORMAT(UNCD.ApprovedDate, "%d-%m-%Y") as FormatDate,UNCD.ApprovedDate,UNCD.UniversityCode,UNCD.UniversityName,UNCD.TypeID,ENU.EnrolmentNo,UNP.BillNo,UNP.PID as PaymentID,UNP.Amount,UNP.ReceiptNo,UNP.Remarks'); $this->db->from(UNIVERSITYCREDITDEBIY.' as UNCD'); $this->db->join(FORMFEESRECEIVEDFROMUNIV.' as UNFR', 'UNFR.ID = UNCD.FormMapID','left'); $this->db->join(UNIVERSITYPAYMENT.' as UNP', 'UNP.PID = UNCD.PaymentMapID','left'); @@ -1467,4 +1467,77 @@ $result['updatedraftStatus'] = false; return $resultArray; } + /* + * update payment details + * created by kms + * */ + public function updatePaymentDetails($update=null,$payment=null,$debit=null){ + $resultArray=array(); + $this->db->where('UNP.BillNo', $payment['BillNo']); + $this->db->where('UNP.PID != ', $update['PaymentID']); + $this->db->select('UNP.BillNo'); + $this->db->from(UNIVERSITYPAYMENT.' as UNP'); + $billExist = $this->db->get(); + if($billExist->num_rows()<=0){ + if($payment['ReceiptNo']!='' AND $payment['ReceiptNo']!=null){ + $this->db->where('UNP1.ReceiptNo', $payment['ReceiptNo']); + $this->db->where('UNP1.PID != ', $update['PaymentID']); + $this->db->select('UNP1.ReceiptNo'); + $this->db->from(UNIVERSITYPAYMENT.' as UNP1'); + $receiptExist = $this->db->get(); + if($receiptExist->num_rows()<=0){ + $this->db->where('PID', $update['PaymentID']); + $this->db->update(UNIVERSITYPAYMENT, $payment); + if ($this->db->affected_rows() > 0) { + $this->db->where('ID', $update['ID']); + $this->db->update(UNIVERSITYCREDITDEBIY, $debit); + if ($this->db->affected_rows() > 0) { + $resultArray['status']=true; + $resultArray['message']="Payment update successfully"; + } + else{ + $resultArray['status']=false; + $resultArray['message']="Payment update failed.try again"; + } + + } else { + $resultArray['status']=false; + $resultArray['message']="Payment failed.Try again"; + } + } + else{ + $resultArray['status']=false; + $resultArray['message']="Receipt no is already exist.."; + } + } + else{ + $this->db->where('PID', $update['PaymentID']); + $this->db->update(UNIVERSITYPAYMENT, $payment); + if ($this->db->affected_rows() > 0) { + $this->db->where('ID', $update['ID']); + $this->db->update(UNIVERSITYCREDITDEBIY, $debit); + if ($this->db->affected_rows() > 0) { + $resultArray['status']=true; + $resultArray['message']="Payment update successfully"; + } + else{ + $resultArray['status']=false; + $resultArray['message']="Payment update failed.try again"; + } + + + } else { + $resultArray['status']=false; + $resultArray['message']="Payment failed.Try again"; + } + + } + } + else { + $resultArray['status']=false; + $resultArray['message']="Bill no is already exist.."; + } + return $resultArray; + + } } \ No newline at end of file diff --git a/Apollo/assets/js/controllers/univFormPaymentCtrl.js b/Apollo/assets/js/controllers/univFormPaymentCtrl.js index c78855d3..0f3bb313 100644 --- a/Apollo/assets/js/controllers/univFormPaymentCtrl.js +++ b/Apollo/assets/js/controllers/univFormPaymentCtrl.js @@ -176,6 +176,152 @@ app.controller('univFormPaymentCtrl', ["$scope","$rootScope","$filter", "ngTable }; $rootScope.addError=""; }; + /* + * update university payment details + * created by kms + * */ + $rootScope.updatePaymentModel = { + 'ID':"", + 'billNo':"", + 'date':"", + 'billAmount':"", + 'receiptNo':"", + 'comments':"", + 'universityCode':"", + 'universityName':"", + 'paymentID':"" + + }; + $rootScope.viewPayment = function (values) { + var updateDate=new Date(values.ApprovedDate).toDateString(); + $rootScope.updateError=""; + $rootScope.updatePaymentModel = { + 'ID': values.ID, + 'billNo':values.BillNo, + 'date':$filter('date')(new Date(updateDate), 'yyyy-MM-dd'), + 'billAmount':values.DebitAmount, + 'receiptNo':values.ReceiptNo, + 'comments':values.Remarks, + 'universityCode':values.UniversityCode, + 'universityName':values.UniversityName, + 'paymentID':values.PaymentID + }; + $rootScope.updatePaymentModal = $modal.open({ + templateUrl: 'assets/views/student/updateUniversityPaymentModal.html', + // controller: 'univFormPaymentCtrl', + // size: size, + resolve: { + items: function () { + return $rootScope.updatePaymentModel; + } + } + }); + + $rootScope.updatePaymentModal.result.then(function (selectedItem) { + }, function () { + $rootScope.updatePaymentModal.close(); + $rootScope.updatePaymentModel = { + 'ID':"", + 'billNo':"", + 'date':"", + 'billAmount':"", + 'receiptNo':"", + 'comments':"", + 'universityCode':"", + 'universityName':"", + 'paymentID':"" + + }; + }); + + } + + $rootScope.updateError=""; + $rootScope.updateUnivPayment = function (form,updateDetails) { + $rootScope.updateError=""; + var firstError = null; + if (form.$invalid) { + + var field = null, firstError = null; + for (field in form) { + if (field[0] != '$') { + if (firstError === null && !form[field].$valid) { + firstError = form[field].$name; + } + if (form[field].$pristine) { + form[field].$dirty = true; + } + } + } + angular.element('.ng-invalid[name=' + firstError + ']').focus(); + // swal("The form cannot be submitted because it contains validation errors!", "Errors are marked with a red, dashed border!", "error"); + } + else{ + var changeDate; + if(angular.isObject(updateDetails.date)){ + var saveDate=new Date(updateDetails.date).toDateString(); + changeDate=$filter('date')(new Date(saveDate), 'yyyy-MM-dd'); + } + else{ + changeDate=updateDetails.date; + + } + $scope.univUpdateData = { + "universityCode":updateDetails.universityCode, + "universityName":updateDetails.universityName, + "billNo":updateDetails.billNo, + "billAmount":updateDetails.billAmount, + "date":changeDate, + "receiptNo":updateDetails.receiptNo, + "comments":updateDetails.comments, + "ID":updateDetails.ID, + "paymentID":updateDetails.paymentID, + } + + var updatePayment = { + method: 'POST', + url: apiPoint.url + 'updateUniversityPaymentDetails/', + headers: { + 'Content-Type': 'application/json' + }, + data: { + localDetails: localDetail, + details: $scope.univUpdateData, + } + }; + $http(updatePayment).then(function (response) { + if (response.data.status==true) { + swal(" ", response.data.message, "success"); + $rootScope.updatePaymentModal.close(); + $rootScope.updatePaymentModel = { + 'ID':"", + 'billNo':"", + 'date':"", + 'billAmount':"", + 'receiptNo':"", + 'comments':"", + 'universityCode':"", + 'universityName':"", + 'paymentID':"" + + }; + $rootScope.getPaymentVerificationDetails($scope.paymentVerficationModel); + + + } else { + $rootScope.updateError=response.data.message; + $timeout(function () { + $rootScope.updateError=""; + }, 4000); + + + } + }); + } + + } + + /* @@ -233,4 +379,24 @@ app.controller('univFormPaymentCtrl', ["$scope","$rootScope","$filter", "ngTable }); }; + /* + * cancel update modal + * */ + $rootScope.cancelUpdatePaymentModal=function () { + $rootScope.updatePaymentModal.close(); + /* $rootScope.updatePaymentModel = { + 'ID':"", + 'billNo':"", + 'date':"", + 'billAmount':"", + 'receiptNo':"", + 'comments':"", + 'universityCode':"", + 'universityName':"", + 'paymentID':"" + + };*/ + $rootScope.updateError=""; + }; + }]); \ No newline at end of file diff --git a/Apollo/assets/views/student/UnivFormPaymentDetails.html b/Apollo/assets/views/student/UnivFormPaymentDetails.html index eb2748c9..c35122ea 100644 --- a/Apollo/assets/views/student/UnivFormPaymentDetails.html +++ b/Apollo/assets/views/student/UnivFormPaymentDetails.html @@ -2,6 +2,10 @@ .universityPaid { background: #f4f4f7 !important; } + .spanCursor{ + cursor: pointer; + + }
@@ -65,6 +69,7 @@
+ @@ -75,7 +80,9 @@ - + + + diff --git a/Apollo/assets/views/student/updateUniversityPaymentModal.html b/Apollo/assets/views/student/updateUniversityPaymentModal.html new file mode 100644 index 00000000..b857d800 --- /dev/null +++ b/Apollo/assets/views/student/updateUniversityPaymentModal.html @@ -0,0 +1,103 @@ +
+
+ + Payment for : {{updatePaymentModel.universityName}} +
+
+
+ + + + Bill no is required +
+
+ + + + Bill amount is required + Enter a valid amount + +
+
+
+ + + Date is required. +
+ +
+
+
+
+ + + +
+
+ + +
+ +
+
+
+
+ {{updateError}} + + + + + +
+
+
+ + +
+ +
\ No newline at end of file From 64a902279d174afaa46d2c518af20d7555c4b85f Mon Sep 17 00:00:00 2001 From: "venbatechnologies@gmail.com" Date: Tue, 11 Sep 2018 11:40:18 +0530 Subject: [PATCH 3/9] data correction --- Apollo/assets/js/controllers/entrycorrectionCtrl.js | 11 ++++++++++- Apollo/assets/js/controllers/studentCtrl.js | 13 +++++++++++++ Apollo/assets/views/edit_course.html | 12 +++++++++++- Apollo/assets/views/entry_correction.html | 2 ++ .../views/student/editStudentCourseDetails.html | 7 +++++-- 5 files changed, 41 insertions(+), 4 deletions(-) diff --git a/Apollo/assets/js/controllers/entrycorrectionCtrl.js b/Apollo/assets/js/controllers/entrycorrectionCtrl.js index 63cdf1a3..1f08ced5 100644 --- a/Apollo/assets/js/controllers/entrycorrectionCtrl.js +++ b/Apollo/assets/js/controllers/entrycorrectionCtrl.js @@ -146,6 +146,10 @@ $scope.universitySearchData = ''; $scope.OpenWindowStatus = false; $scope.editId = -1; + $scope.courselist =''; + $scope.loadfee=''; + $scope.feecheck=false; + $scope.setEditId = function (P) { //alert(JSON.stringify(P)); @@ -173,11 +177,16 @@ $scope.universitySearchData = ''; $scope.feeInfo=response.data.details; console.log($scope.feeInfo); $scope.editId = P.ID; + $scope.courselist =true; + $scope.feecheck=false; + } else { $scope.feeInfo=""; $scope.loadfee = "No Records Found"; - + $scope.courselist =false; + $scope.feecheck=true; + $scope.editId = P.ID; } }); diff --git a/Apollo/assets/js/controllers/studentCtrl.js b/Apollo/assets/js/controllers/studentCtrl.js index 368406f3..9efa8d26 100755 --- a/Apollo/assets/js/controllers/studentCtrl.js +++ b/Apollo/assets/js/controllers/studentCtrl.js @@ -721,12 +721,15 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams", $scope.editId = -1; $scope.editCourseId = -1; $scope.setEditId = function (unique_id, id) { + + // alert() $scope.editId = unique_id; $scope.editCourseId = -1; $scope.studentViewPage = -1; } $scope.setEditCourseId = function (unique_id,id) { + $scope.list = false; $scope.getStudentCourseList(id); $scope.currentStudentId = id; @@ -837,6 +840,8 @@ app.controller('studentCtrl', ["$scope", "toaster", "$filter", "ngTableParams", // get Student Course List $scope.getStudentCourseList = function (studentId) { + + console.log('in') $scope.courseEditLoading = true; $scope.list = true; $scope.courseEdit = false; @@ -1740,11 +1745,15 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl $scope.editId = -1; $scope.editCourseId = -1; $scope.setEditId = function (uniqe_id ,id) { + + // alert() $scope.editId = uniqe_id; $scope.editCourseId = -1; } $scope.setEditCourseId = function (uniqe_id ,id) { + + //alert('1'); $scope.list = false; $scope.getStudentCourseList(id); $scope.currentStudentId = id; @@ -1752,6 +1761,7 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl $scope.editCourseId = uniqe_id; $scope.editId = -1; $scope.courseEditLoading = true; + $scope.courselist = true; } @@ -1879,6 +1889,9 @@ app.controller('studentSuperAdminCtrl', ["$scope", "toaster", "$filter", "ngTabl $scope.studentCourseList = response.data.course_details; // $scope.stucour = $scope.studentCourse[0]; } else { + + $scope.courselist = false; + $scope.courseEditLoading=''; } }); } diff --git a/Apollo/assets/views/edit_course.html b/Apollo/assets/views/edit_course.html index 2abf1c2e..c4aff4fd 100644 --- a/Apollo/assets/views/edit_course.html +++ b/Apollo/assets/views/edit_course.html @@ -1,6 +1,8 @@
+ +
@@ -26,7 +28,15 @@ -
+ +
+

No Records Found

+
+
Form ID Enrolment No Bill No Date Payable Paid Balance
{{p.FormID}} {{p.EnrolmentNo}}{{p.BillNo}}{{p.BillNo}}{{p.FormatDate}} {{p.CreditAmount}}
diff --git a/Apollo/assets/views/entry_correction.html b/Apollo/assets/views/entry_correction.html index e399e5ed..5a9fe889 100644 --- a/Apollo/assets/views/entry_correction.html +++ b/Apollo/assets/views/entry_correction.html @@ -167,6 +167,8 @@ + +
diff --git a/Apollo/assets/views/student/editStudentCourseDetails.html b/Apollo/assets/views/student/editStudentCourseDetails.html index a2746822..7829b4cb 100755 --- a/Apollo/assets/views/student/editStudentCourseDetails.html +++ b/Apollo/assets/views/student/editStudentCourseDetails.html @@ -6,12 +6,15 @@ })
- +

Fetching ...

+
+

No Records Found

+
-
+
Course Details From fe19d226e0038ff1c00f9d6706b844b780890d7b Mon Sep 17 00:00:00 2001 From: dineshkumarkannan Date: Tue, 11 Sep 2018 12:05:43 +0530 Subject: [PATCH 4/9] pagination changes : kdk --- .../views/student/studentUnivFormIdFeeDetails.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html b/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html index 09eecdf4..403f1949 100644 --- a/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html +++ b/Apollo/assets/views/student/studentUnivFormIdFeeDetails.html @@ -167,7 +167,7 @@ - + @@ -307,7 +307,7 @@ - +
@@ -460,7 +460,7 @@ Amount - + @@ -673,7 +673,7 @@ - + @@ -779,7 +779,7 @@ CourseFee Amount - + {{p.FormID}} {{p.FormType}} @@ -791,7 +791,7 @@ - + From bdafbe21084f3b25f85bfd69204929f3acece293 Mon Sep 17 00:00:00 2001 From: gayathri1990 Date: Tue, 11 Sep 2018 12:55:03 +0530 Subject: [PATCH 5/9] batchschdule changes --- .../controllers/HallTickets_Controller.php | 59 ++++++++++++------ .../application/models/Hallticket_model.php | 43 ++++++++++--- Apollo/assets/js/controllers/schCtrl.js | 4 +- .../assets/views/hallticket/batchshedule.html | 5 +- .../assets/views/hallticket/editShedule.html | 2 +- Apollo/images/Batchschedule.xlsx | Bin 0 -> 10236 bytes 6 files changed, 82 insertions(+), 31 deletions(-) create mode 100644 Apollo/images/Batchschedule.xlsx diff --git a/Apollo/api/application/controllers/HallTickets_Controller.php b/Apollo/api/application/controllers/HallTickets_Controller.php index 33906862..5a9be8a7 100644 --- a/Apollo/api/application/controllers/HallTickets_Controller.php +++ b/Apollo/api/application/controllers/HallTickets_Controller.php @@ -16,7 +16,7 @@ class HallTickets_Controller extends REST_Controller { function __construct() { - // Construct the parent class + // Construct the parent class parent::__construct(); // Configure limits on our controller methods @@ -320,13 +320,27 @@ class HallTickets_Controller extends REST_Controller { $branchId = $this->post('branchId'); $Cdate = new DateTime('now',new DateTimeZone('Asia/Kolkata')); $CreatedOn = $Cdate->format('Y-m-d H:i:s'); -/////////check semcoursemapping//// - // $data['subjectDetails'] = $this->Hallticket_model->getSubjectDetails($universityID,$tempCourseArray,$branchId); - $data['subjectDetails'] = $this->Hallticket_model->getExistDetailsfileupload($university,$courseArray,$branchId); - // print_r( $data['subjectDetails']); - if($data['subjectDetails'] == 1 ) + $fileArray = array(); + foreach($filedetails as $filedetailsarray) + { + $fileArray[]=$filedetailsarray['SubjectID']; + } + + $data['subjectDetails'] = $this->Hallticket_model->getExistDetailsfileupload($university,$courseArray,$branchId); + // print_r( $data['subjectDetails']); + if($data['subjectDetails'] == 1 ) { - foreach($courseArray as $CourseDatialArray) + + $data['SubjectMappingDetails'] = $this->Hallticket_model->getSubjectMappingDetails($university,$courseArray,$branchId); + $maparray=array(); + foreach ( $data['SubjectMappingDetails'] as $object) + { + $maparray[]=$object->SubjectCode; + } + if ($fileArray == $maparray) + { + + foreach($courseArray as $CourseDatialArray) { $course=$CourseDatialArray; $schedulemaster = array('UniversityID'=>$university,'CourseID'=>$course,'BranchCode'=>$branchId,'CreatedBy'=>$requestedBy,'CreatedOn'=>$CreatedOn); @@ -355,28 +369,35 @@ class HallTickets_Controller extends REST_Controller { 'status' => REST_Controller::HTTP_NOT_FOUND ], REST_Controller::HTTP_NOT_FOUND); - } + } + } + else + { + $this->response([ + 'message' => 'Records Do Not Match With Mapped Subjects!', + 'status' => REST_Controller::HTTP_NOT_FOUND + ], REST_Controller::HTTP_NOT_FOUND); + } } // else if($data['subjectDetails'] == 0) else { $this->response([ - 'message' => 'Please Mapping the course supject!', + 'message' => ' Course Mapping for the Subject Not Found !', 'status' => REST_Controller::HTTP_NOT_FOUND ], REST_Controller::HTTP_NOT_FOUND); } - // else{ - - // $this->response([ - // 'message' => 'No records found!', - // 'status' => REST_Controller::HTTP_NOT_FOUND - // ], REST_Controller::HTTP_NOT_FOUND); - - // } -///////////////////// - + + + + + + + + + } public function SaveAllBatchSchedule_post() diff --git a/Apollo/api/application/models/Hallticket_model.php b/Apollo/api/application/models/Hallticket_model.php index a11cd9b0..4c17cf0e 100644 --- a/Apollo/api/application/models/Hallticket_model.php +++ b/Apollo/api/application/models/Hallticket_model.php @@ -10,7 +10,7 @@ class Hallticket_model extends CI_Model { - + /* * get university details * created by velz @@ -122,7 +122,7 @@ class Hallticket_model extends CI_Model and bsm.CourseID=semmaster.CourseID LEFT JOIN T_Batch_Schedule_Child bsc ON bsc.SchId = bsm.SchId and bsc.SubjectID=semchild.SubjectID LEFT JOIN T_SubjectMaster sm ON sm.SubjectID=semchild.SubjectID -WHERE semchild.isActive = '1' and bsm.SchId='".$mapid."' +WHERE semchild.isActive = '1' and bsm.SchId='".$mapid."' group by semchild.SubjectID,semchild.MapID"; $b=$this->db->query($sql); //print_r($b); @@ -135,8 +135,8 @@ group by semchild.SubjectID,semchild.MapID"; $this->db->select('T_Batch_Schedule_Child.SchId,T_Batch_Schedule_Child.SubjectID,T_Batch_Schedule_Child.ScheduleDate,T_Batch_Schedule_Child.FromTime,T_Batch_Schedule_Child.ToTime,T_Batch_Schedule_Child.SchChildId,T_Batch_Schedule_Child.SchId'); $this->db->from('T_Batch_Schedule_Master SCM'); $this->db->join('T_Batch_Schedule_Child','T_Batch_Schedule_Child.SchId = SCM.SchId'); - //$this->db->where('SCM.BranchCode',$branchcode); - // $this->db->where('T_Batch_Schedule_Child.SchId',$mapid); + $this->db->where('SCM.BranchCode',$branchcode); + $this->db->where('T_Batch_Schedule_Child.SchId',$mapid); $this->db->where('T_Batch_Schedule_Child.SubjectID',$row->SubjectID); $existsheduledetails = $this->db->get(); //print_r($existsheduledetails); @@ -200,16 +200,16 @@ group by semchild.SubjectID,semchild.MapID"; public function getExistDetailsfileupload($universityID,$courseIDS,$branchId) { -// print_r($courseIDS); -// echo $universityID; + $i=0; foreach($courseIDS as $c) { // $tempCourseArray= $c['CourseID']; - $this->db->select ('count(*) as count'); + $this->db->select ('count(*) as count,T_SemSubMap_Child.SubjectID'); $this->db->from('T_SemSubMap_Master'); + $this->db->join('T_SemSubMap_Child','T_SemSubMap_Child.MapID=T_SemSubMap_Master.MapID'); $this->db->where('UniversityID',$universityID); $this->db->where('CourseID',$c); $result = $this->db->get(); @@ -235,6 +235,35 @@ public function getExistDetailsfileupload($universityID,$courseIDS,$branchId) * @params university id and CourseID * created by Bala * */ +public function getSubjectMappingDetails($universityID,$courseIDS,$branchId) + { + + + + foreach($courseIDS as $c) + { + + // $tempCourseArray= $c['CourseID']; + + $this->db->select ('T_SubjectMaster.SubjectCode'); + $this->db->from('T_SemSubMap_Master'); + $this->db->join('T_SemSubMap_Child','T_SemSubMap_Child.MapID=T_SemSubMap_Master.MapID'); + $this->db->join('T_SubjectMaster','T_SubjectMaster.SubjectID=T_SemSubMap_Child.SubjectID'); + $this->db->where('T_SemSubMap_Master.UniversityID',$universityID); + $this->db->where('T_SemSubMap_Master.CourseID',$c); + $this->db->where('T_SubjectMaster.BranchCode',$branchId); + $result = $this->db->get(); + + + } + return $result->result(); + + } + /* + * check existing data,only batchschedule. + * @params university id and CourseID + * created by Bala + * */ public function getExistDetails($universityID,$courseIDS,$branchId) { diff --git a/Apollo/assets/js/controllers/schCtrl.js b/Apollo/assets/js/controllers/schCtrl.js index 8f5bd0a3..bacbd138 100644 --- a/Apollo/assets/js/controllers/schCtrl.js +++ b/Apollo/assets/js/controllers/schCtrl.js @@ -14,7 +14,7 @@ app.controller('schCtrl', ["$scope","$rootScope","toaster", "$filter", "ngTableP $scope.myModelAdd = { "date": "", - "periodStart": "", + "periodStart": "", "periodEnd":"", }; @@ -384,7 +384,7 @@ $scope.UploadFileData = function (FileDetails,myModel,courseDetails) { swal("", "Saved Successfully", "success"); $state.go($state.current, {}, {reload: true}); } else { - swal("", "Please Mapping the course supject", "error"); + swal("",response.data.message, "error"); $state.go($state.current, {}, {reload: true}); } },function(error){ diff --git a/Apollo/assets/views/hallticket/batchshedule.html b/Apollo/assets/views/hallticket/batchshedule.html index be0cc8d1..b54daebc 100644 --- a/Apollo/assets/views/hallticket/batchshedule.html +++ b/Apollo/assets/views/hallticket/batchshedule.html @@ -16,7 +16,7 @@ } a { - color: #007AFF; + color: #007AFF; } @@ -167,7 +167,8 @@

- Sample Format + + Sample Format
diff --git a/Apollo/assets/views/hallticket/editShedule.html b/Apollo/assets/views/hallticket/editShedule.html index 03090b7c..5f792e9a 100644 --- a/Apollo/assets/views/hallticket/editShedule.html +++ b/Apollo/assets/views/hallticket/editShedule.html @@ -6,7 +6,7 @@ Update Schedule Details -
+
@@ -67,7 +67,7 @@ Form ID - Enrolment No + Enrollment ID Bill No Date Payable diff --git a/Apollo/assets/views/student/studentUnivFeeCompareDetails.html b/Apollo/assets/views/student/studentUnivFeeCompareDetails.html index 3c03b06a..08d5c891 100644 --- a/Apollo/assets/views/student/studentUnivFeeCompareDetails.html +++ b/Apollo/assets/views/student/studentUnivFeeCompareDetails.html @@ -2,8 +2,8 @@
-

{{ mainTitle }}

- Student Form Enrolment Details. +

{{ mainTitle }}

+ Student Form Enrollment Details.
@@ -43,7 +43,7 @@
- +
- +
@@ -60,7 +60,7 @@
- Add Enrolment Details + Add Enrollment Details
@@ -68,7 +68,7 @@
Enrolment no is required + ng-hide="manualEnForm.manualEnrolmentNo.$error.maxlength || manualEnForm.manualEnrolmentNo.$error.minlength || manualEnForm.manualEnrolmentNo.$error.pattern">Enrollment no is required Enter a valid enrolment no + ng-if="manualEnForm.manualEnrolmentNo.$error.maxlength || manualEnForm.manualEnrolmentNo.$error.minlength || manualEnForm.manualEnrolmentNo.$error.pattern">Enter a valid enrollment no
@@ -172,7 +172,7 @@
@@ -334,7 +332,7 @@
- +
@@ -344,11 +342,11 @@
Loading...
-
No Record Found ...
+
No record found ...
-
+
@@ -359,7 +357,7 @@ - + @@ -377,7 +375,7 @@ - + @@ -402,7 +400,7 @@
FormIDEnrolmentNoEnrollment ID SemesterYear MobileNumber StudentName
{{p.FormID}} {{p.EnrolmentNo}}
- +
From f2f8b99f7edb6be5a0d1c932a9f0522116625775 Mon Sep 17 00:00:00 2001 From: gandhimathi Date: Tue, 11 Sep 2018 14:38:57 +0530 Subject: [PATCH 7/9] common files changes for nav options --- ...Receive_Enrolment_Fees_Univ_Controller.php | 5 +- Apollo/assets/i18n/en.json | 7 +++ Apollo/assets/js/config.router.js | 54 +++++++++++-------- Apollo/assets/views/partials/nav.html | 49 +++++++++++------ 4 files changed, 73 insertions(+), 42 deletions(-) diff --git a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php index 6aa47610..39ebe638 100644 --- a/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php +++ b/Apollo/api/application/controllers/Receive_Enrolment_Fees_Univ_Controller.php @@ -165,9 +165,8 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller { // Set the response and exit $this->response($getUnmatchedFormDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } - if ($getUnmatchedFormDetails['unMatchedRecordStatus']==false) + else if ($getUnmatchedFormDetails['unMatchedRecordStatus']==false) { - $getUnmatchedFormDetails['status'] = false; // Set the response and exit $this->response($getUnmatchedFormDetails, REST_Controller::HTTP_OK); // OK (200) being the HTTP response code } @@ -176,7 +175,7 @@ class Receive_Enrolment_Fees_Univ_Controller extends REST_Controller { // Set the response and exit $this->response([ 'message' => 'Something went wrong.please try again!', - 'status' => REST_Controller::HTTP_NOT_FOUND + 'formTypeStatus' => false ], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code } } diff --git a/Apollo/assets/i18n/en.json b/Apollo/assets/i18n/en.json index 81f26042..610733c7 100755 --- a/Apollo/assets/i18n/en.json +++ b/Apollo/assets/i18n/en.json @@ -118,6 +118,13 @@ "APPLICATION": "Application" } }, + "formupload": { + "MAIN": "UNIVERSITY FORMS", + "ENROLLMENT": "Enrollment", + "STUDENTFEEDETAILCOMPARE": "Form Enrolment", + "STUDENTFROMIDFEEDETAILS": "Form Fees", + "UNIVERSITYFORMPAYMENT": "Payment" + }, "status": { "MAIN": "STATUS", "APPLICATION": "Application", diff --git a/Apollo/assets/js/config.router.js b/Apollo/assets/js/config.router.js index ac339ca7..233770c9 100755 --- a/Apollo/assets/js/config.router.js +++ b/Apollo/assets/js/config.router.js @@ -307,30 +307,14 @@ app.config(['$stateProvider', '$urlRouterProvider', '$controllerProvider', '$com ncyBreadcrumb: { label: 'Manage Details' } - }).state('app.student.UnivFormEnroment', { - url: '/univformenrolment', - templateUrl: "assets/views/student/studentUnivFeeCompareDetails.html", - resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'student_university_fee_compareCtrl', 'ngTable'), - title: 'University Form Enrolment', + }) + .state('app.formupload', { + url: '/student', + template: '
STUDENT DETAILS
', + title: 'Student', ncyBreadcrumb: { - label: 'University Form Enrolment' + label: 'Student' } - }).state('app.student.studentUnivFormIdFeeDetails', { - url: '/studentUnivFormIdFeeDetails', - templateUrl: "assets/views/student/studentUnivFormIdFeeDetails.html", - resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'studentUnivFormIdFeeDetailsCtrl', 'ngTable'), - title: 'Student FormId Fees Details', - ncyBreadcrumb: { - label: 'Student FormId Fees Details' - } - }).state('app.student.universityformpayment', { - url: '/univformpayment', - templateUrl: "assets/views/student/UnivFormPaymentDetails.html", - resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'univFormPaymentCtrl', 'ngTable'), - title: 'University Form Payment Details', - ncyBreadcrumb: { - label: 'University Form Payment Details' - } }).state('app.student.status', { url: '/status', template: '
STUDENT STATUS UPDATE
', @@ -816,7 +800,31 @@ app.config(['$stateProvider', '$urlRouterProvider', '$controllerProvider', '$com label: 'Student Merge' }, - }); + }).state('app.formupload.UnivFormEnroment', { + url: '/univformenrolment', + templateUrl: "assets/views/student/studentUnivFeeCompareDetails.html", + resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'student_university_fee_compareCtrl', 'ngTable'), + title: 'University Form Enrolment', + ncyBreadcrumb: { + label: 'University Form Enrolment' + } + }).state('app.formupload.studentUnivFormIdFeeDetails', { + url: '/studentUnivFormIdFeeDetails', + templateUrl: "assets/views/student/studentUnivFormIdFeeDetails.html", + resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'studentUnivFormIdFeeDetailsCtrl', 'ngTable'), + title: 'Student FormId Fees Details', + ncyBreadcrumb: { + label: 'Student FormId Fees Details' + } + }).state('app.formupload.universityformpayment', { + url: '/univformpayment', + templateUrl: "assets/views/student/UnivFormPaymentDetails.html", + resolve: loadSequence('ui.select', 'spin', 'ui.mask', 'monospaced.elastic', 'ladda', 'touchspin-plugin', 'angular-ladda', 'univFormPaymentCtrl', 'ngTable'), + title: 'University Form Payment Details', + ncyBreadcrumb: { + label: 'University Form Payment Details' + } + }); // $locationProvider.html5Mode(true); diff --git a/Apollo/assets/views/partials/nav.html b/Apollo/assets/views/partials/nav.html index ac7b1ce1..4a63052d 100755 --- a/Apollo/assets/views/partials/nav.html +++ b/Apollo/assets/views/partials/nav.html @@ -180,7 +180,7 @@ -->
  • - + Status Update
  • -
  • - - University Form Enrolment - -
  • -
  • - - STUDENT FORMID FEE DETAILS - -
  • -
  • - - University Form Payment - -
  • + + Sample Format