PageSourceSearch

https://fxboss.firstcitizens.com/app/dashboardWidget/casf_flow_cur…sh_flow_curve_controller.js?v=31082026-1758

js firstcitizens.com collected 2026-09-24 21:52:23 UTC 1,985 bytes, 50 lines download raw bytes

1var app = angular.module('bossApp');
2app.controller('cashFlowCurveCtrl', ['$scope', '$rootScope','DashboardService',
3function($scope, $rootScope,DashboardService) {
4	$scope.generateCashFlow = false;
5	/*
6     * Set Default date for searching.
7     */
8
9    $scope.renderCount = 1;
10    var _date = new Date();
11    var _firstDay = new Date(_date.getFullYear(), _date.getMonth(), 1);
12    var _lastDay = new Date(_date.getFullYear(), _date.getMonth() + 1, 0);
13    $scope.cfDate = {
14        cashFlowDateFrom: _firstDay,
15        cashFlowDateTo: _lastDay
16    }
17    generateCashFlow(_firstDay, _lastDay);
18	/**
19     * Curve Plot for Invoice Dashboard.
20     */
21    function generateCashFlow(dateFrom, dateTo) {
22
23        DashboardService.getCashFlowPlot(dateFrom, dateTo).then(function(data) {
24            var finalCashFlowList = [];
25            var item = {
26                date: undefined,
27                invoice: undefined,
28                payment: undefined,
29                cashflow: undefined
30            };
31
32            for (var i in data.cashBalanceList) {
33                var date = new Date(data.cashBalanceList[i].projectionDate);
34                item.date = angular.copy((date.getDate()).toString());
35                item.invoice = angular.copy(data.cashBalanceList[i].invoiceAmount);
36                item.payment = angular.copy(data.cashBalanceList[i].paymentAmount);
37                item.cashflow = angular.copy(data.cashBalanceList[i].projectedBalance);
38                finalCashFlowList.push(angular.copy(item));
39            }
40            $scope.cashFlowData = finalCashFlowList;
41            $scope.generateCashFlow = true;
42        });
43    }
44	/** Watcher **/
45    $scope.$watchCollection('[cfDate.cashFlowDateFrom,cfDate.cashFlowDateTo]', function() {
46        if (($scope.cfDate.cashFlowDateFrom instanceof Date) && ($scope.cfDate.cashFlowDateTo instanceof Date)) {
47            //generateCashFlow($scope.cfDate.cashFlowDateFrom, $scope.cfDate.cashFlowDateTo);
48        }
49    });
50}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.