Exemplo n.º 1
0
        public MasterReportBound GetReceiveReport(ReceiptsViewModel receiptsViewModel)
        {
            List <Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain> reports = new List <ReceiveReportMain>();

            Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain receivereport = new Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain();
            UserProfile user = _userProfileService.GetUser(User.Identity.Name);

            receivereport.receiveReports = _transactionService.GetReceiveReport(user.DefaultHub.HubID, receiptsViewModel);//new List<ViewModels.Report.Data.ReceiveReport>();
            receivereport.PreparedBy     = user.GetFullName();
            receivereport.HubName        = user.DefaultHub.HubNameWithOwner;
            receivereport.ReportDate     = System.DateTime.Now;
            receivereport.ReportCode     = DateTime.Now.ToString();
            receivereport.ReportName     = "ReceiveReport";
            receivereport.ReportTitle    = "Receive Report";

            Cats.Web.Hub.Reports.ReceiveReportByBudgetYear rpt = new ReceiveReportByBudgetYear()
            {
                DataSource = receivereport.receiveReports
            };
            MasterReportBound report = new MasterReportBound()
            {
                Name = "Receive Report - " + DateTime.Now.ToShortDateString(), DataSource = reports
            };

            report.rptSubReport.ReportSource = rpt;
            return(report);
        }
Exemplo n.º 2
0
        public MasterReportBound GetReceiveReport(ReceiptsViewModel receiptsViewModel)
        {
            List<Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain> reports = new List<ReceiveReportMain>();
            Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain receivereport = new Cats.Models.Hub.ViewModels.Report.Data.ReceiveReportMain();
            UserProfile user = _userProfileService.GetUser(User.Identity.Name);

            receivereport.receiveReports = _transactionService.GetReceiveReport(user.DefaultHub.HubID, receiptsViewModel);//new List<ViewModels.Report.Data.ReceiveReport>();
            receivereport.PreparedBy = user.GetFullName();
            receivereport.HubName = user.DefaultHub.HubNameWithOwner;
            receivereport.ReportDate = System.DateTime.Now;
            receivereport.ReportCode = DateTime.Now.ToString();
            receivereport.ReportName = "ReceiveReport";
            receivereport.ReportTitle = "Receive Report";

            Cats.Web.Hub.Reports.ReceiveReportByBudgetYear rpt = new ReceiveReportByBudgetYear() { DataSource = receivereport.receiveReports };
            MasterReportBound report = new MasterReportBound() { Name = "Receive Report - " + DateTime.Now.ToShortDateString(), DataSource = reports };
            report.rptSubReport.ReportSource = rpt;
            return report;
        }