Feature: Automatic Crediting of Service Points. Plus now service points can be decimals

This commit is contained in:
tanshu committed 2014-12-25 16:40:47 +05:30
1 parent c27276cc05
commit 7c54e4b0c7
7 files changed
+148 -7

No files matched your search

@@ -17,6 +17,25 @@ var EmployeeFunctionsController = ['$scope', '$http', 'asDateFilter', function (
});
};
$scope.creditServiceCharge = function () {
if (!angular.isDate($scope.sc.Month)) {
return;
}
var ServiceChargeMonth = asDate($scope.sc.Month);
if (!angular.isDate($scope.sc.CreditDate)) {
return;
}
var CreditDate = asDate($scope.sc.CreditDate);
return $http.
post('/api/CreditServiceCharge', {Month: ServiceChargeMonth, CreditDate: CreditDate}).
success(function (data) {
$scope.toasts.push({Type: 'Success', Message: data.message});
}).
error(function (errorMessage) {
$scope.toasts.push({Type: 'Danger', Message: errorMessage});
});
};
$scope.attendanceRecordUrl = function () {
if (!$scope.record.StartDate || !$scope.record.FinishDate) {
return;