pl report excel
This commit is contained in:
parent
4f8ac91cbb
commit
6fd0fdffe2
@ -109,6 +109,7 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
$scope.nonopexptotal='';
|
$scope.nonopexptotal='';
|
||||||
$scope.Net_Total = '';
|
$scope.Net_Total = '';
|
||||||
$scope.PLexceldetails='';
|
$scope.PLexceldetails='';
|
||||||
|
$scope.expense ='';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -244,10 +245,6 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// console.log($scope.opinctotal)
|
|
||||||
|
|
||||||
// console.log($scope.opexptotal)
|
|
||||||
|
|
||||||
angular.forEach(($scope.nonopdetails),function(nonopdetails,key)
|
angular.forEach(($scope.nonopdetails),function(nonopdetails,key)
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -267,27 +264,11 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// console.log($scope.nonopinctotal)
|
|
||||||
//console.log($scope.nonopexptotal)
|
|
||||||
|
|
||||||
|
|
||||||
$scope.Net_Total = (parseFloat($scope.opinctotal)+parseFloat($scope.nonopinctotal))-
|
$scope.Net_Total = (parseFloat($scope.opinctotal)+parseFloat($scope.nonopinctotal))-
|
||||||
|
|
||||||
(parseFloat($scope.opexptotal)+parseFloat($scope.nonopexptotal) );
|
(parseFloat($scope.opexptotal)+parseFloat($scope.nonopexptotal) );
|
||||||
|
|
||||||
//console.log($scope.Net_Total)
|
|
||||||
|
|
||||||
// console.log($scope.Total_income)
|
|
||||||
|
|
||||||
// console.log($scope.nonopinctotal)
|
|
||||||
|
|
||||||
// console.log($scope.Total_expense)
|
|
||||||
|
|
||||||
// console.log($scope.nonopexptotal)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -298,6 +279,8 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
var getsubdivision = {
|
var getsubdivision = {
|
||||||
@ -369,12 +352,6 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -397,33 +374,30 @@ app.controller('income_reportCtrl', ["$scope","$rootScope","toaster", "$filter",
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
$scope.Newexcel={
|
|
||||||
// "OperationalIncome":"",
|
|
||||||
// "NonOperationalIncome":"",
|
|
||||||
// "OperationalExpense":"",
|
|
||||||
// "NonOperationalExpense":"",
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
// $scope.Newexcel=[];
|
|
||||||
|
|
||||||
$scope.exportData = function ()
|
$scope.exportData = function ()
|
||||||
{
|
{
|
||||||
//alert()
|
// angular.forEach(($scope.PLexceldetails),function(PLexceldetails,key)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// console.log(PLexceldetails.Name)
|
||||||
|
|
||||||
|
// });
|
||||||
|
|
||||||
|
//return false;
|
||||||
|
|
||||||
$scope.Newexcel.OperationalIncome=$scope.opinctotal;
|
$scope.grandTot =
|
||||||
$scope.Newexcel.NonOperationalIncome=$scope.nonopinctotal;
|
{
|
||||||
$scope.Newexcel.OperationalExpense=$scope.opexptotal;
|
|
||||||
$scope.Newexcel.NonOperationalExpense=$scope.nonopexptotal;
|
NonOperationalExpense:"Grand Total",
|
||||||
|
ListName: $scope.Net_Total
|
||||||
|
}
|
||||||
|
|
||||||
|
$scope.expense = $scope.PLexceldetails.concat($scope.grandTot);
|
||||||
|
|
||||||
//console.log($scope.Newexcel);
|
alasql('SELECT Date,OperationalIncome,NonOperationalIncome,OperationalExpense,NonOperationalExpense,ListName as Type INTO XLS("Income Expense report.xls",?) FROM ?',[mystyle,$scope.expense]);
|
||||||
//return false;
|
|
||||||
|
|
||||||
//console.log($scope.fullincomedetail);
|
|
||||||
alasql('SELECT ListName as Type,Date,OperationalIncome,NonOperationalIncome,OperationalExpense,NonOperationalExpense INTO XLS("Income Expense report.xls",?) FROM ?',[mystyle,$scope.PLexceldetails]);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user