From a130e672c7eaf7903dadea117def12ad981bb574 Mon Sep 17 00:00:00 2001 From: gandhimathi Date: Tue, 22 May 2018 11:34:14 +0530 Subject: [PATCH] fees paid counts added in db for report --- Apollo/assets/js/controllers/feesStatusCtrl.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Apollo/assets/js/controllers/feesStatusCtrl.js b/Apollo/assets/js/controllers/feesStatusCtrl.js index 9cd324d7..dd1ce883 100755 --- a/Apollo/assets/js/controllers/feesStatusCtrl.js +++ b/Apollo/assets/js/controllers/feesStatusCtrl.js @@ -498,6 +498,13 @@ app.controller('feesStatusCtrl', ["$scope","$rootScope","toaster", "$filter", "n } angular.element('.ng-invalid[name=' + firstError + ']').focus(); } else { + // count exist payment length report purpose + $scope.existPaidCount=1; + angular.forEach($scope.existStudentFeesDetails,function (values) { + if(updateModel.feesType.FeesID==values.FeesID){ + $scope.existPaidCount=parseInt($scope.existPaidCount)+parseInt(values.paidDetails.length); + } + }); $scope.ldloading = {}; $scope.ldloading[loading.replace('-', '_')] = true; @@ -519,7 +526,6 @@ app.controller('feesStatusCtrl', ["$scope","$rootScope","toaster", "$filter", "n billDate: $scope.billDate, billAmount:updateModel.billAmount, modeOfPayment: updateModel.paymentOn.paymentOn, - commentsForStudent: updateModel.studComments, internalComments: updateModel.internalComments, createdBy: JSON.parse(localStorage.getItem('localObj')).localUserID, @@ -529,7 +535,8 @@ app.controller('feesStatusCtrl', ["$scope","$rootScope","toaster", "$filter", "n course: myModel.CourseName, //statusCode: updateModel.statusCode, requestedBranch : JSON.parse(localStorage.getItem('localObj')).localBranchID, - currentBalance : $scope.currentBalance + currentBalance : $scope.currentBalance, + existPaidCount : $scope.existPaidCount }