Exemplo n.º 1
0
        public DataTable GetData(int ReportId, int ProgramTypeId, string Quarter, string InvoicePeriod)
        {
            DataTable   list = new DataTable();
            UserAccount u    = (UserAccount)Session["UserAccount"];

            switch (ReportId)
            {
            case 1:
                list = DistributorBudgetReportDataTable(_reportDao.GetDistributorBudgetReports(ProgramTypeId), ProgramTypeId);
                break;

            case 2:
                list = ToDataTable(_reportDao.GetClaimReports(Quarter, ProgramTypeId));
                break;

            case 3:
                list = ToDataTable(_reportDao.GetSpendingReports(ProgramTypeId));
                break;

            case 4:
                list = RemoveDataTable(_reportDao.GetPaymentReports(Quarter, InvoicePeriod, ProgramTypeId), ProgramTypeId, Quarter, InvoicePeriod.ToUpper());
                break;

            case 5:
                list = ToDataTable(_reportDao.GetDistributortReports(ProgramTypeId));
                break;

            case 6:
                list = MonthlyDataTable(_reportDao.GetMonthlyPaymentReports(InvoicePeriod, ProgramTypeId), ProgramTypeId);
                break;

            case 7:
                list = ToDataTable(_reportDao.GetMonthlyClaimReport(InvoicePeriod, ProgramTypeId));
                break;
            }

            return(list);
        }