Exemplo n.º 1
0
        public ActionResult Header()
        {
            var Logginuser   = _userAppService.GetLoggedInUser();
            var userInfo     = _userAppService.GetUserLogidInInfo();
            var finacialYear = _financialYearAppService.GetActiveFinancialYear();

            var header = new HeaderDto {
                dealers       = _dealerAppService.GetTotalDealerByStationId(_stationAppService.GetStation(Logginuser.StationId), finacialYear),
                licenses      = _licenseAppService.GetTotalLicenseByStationId(Logginuser.StationId),
                bills         = _billAppService.GetTotalBillsByStation(_stationAppService.GetStation(Logginuser.StationId), finacialYear),
                financialYear = _financialYearAppService.GetActiveFinancialYear(),
                UserInfo      = userInfo
            };

            return(PartialView("_Header", header));
        }
Exemplo n.º 2
0
        public ActionResult Dashboard()
        {
            var finacialYear = _financialYearAppService.GetActiveFinancialYear();
            var userInfo     = _userAppService.GetLoggedInUser();

            var Dashboard = new RegistrationDashboard
            {
                candidates         = _candidateAppService.GetTotalCandidatesByStationId(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                pending            = _dealerAppService.GetTotalPendingDealerByStationId(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                dealers            = _dealerAppService.GetTotalDealerByStationId(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                estimatedVolume    = _candidateAppService.GetTotalAppliedVolumeByStation(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                TotalCollection    = _dealerAppService.GetTotalDealerFeesByStation(_stationAppService.GetStation(userInfo.StationId), finacialYear).Sum(),
                dealersPerMonth    = _dealerAppService.GetTotalMonthDealerByStationId(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                pendingPerMonth    = _dealerAppService.GetTotalMonthPendingDealerByStationId(_stationAppService.GetStation(userInfo.StationId), finacialYear),
                CollectionPerMonth = _dealerAppService.GetTotalMonthDealerFeesByStation(_stationAppService.GetStation(userInfo.StationId), finacialYear).Sum()
            };

            return(View(Dashboard));
        }