// -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Traineeships FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrFm25FundLineGroup(byte currentPeriod, IPeriodisedValuesLookup periodisedValues)
        {
            var fundLineGroup = new FundLineGroup($"ILR Total 16-18 Traineeships (£)", currentPeriod, FundingDataSource.FM25, null, periodisedValues)
                                .WithFundLine($"ILR 16-18 Traineeships Programme Funding (£)", new[] { FundLineConstants.TraineeshipsAdultFunded1618 }, new[] { AttributeConstants.Fm25LrnOnProgPay })
                                .WithFundLine($"ILR 19-24 Traineeships (16-19 Model) Programme Funding (£)", new[] { FundLineConstants.TraineeshipsAdultFunded19Plus }, new[] { AttributeConstants.Fm25LrnOnProgPay });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build EAS Trailblazer Apprenticeships FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildEasAuthorisedClaimsExcessLearningSupportFundLineGroup(string ageRange, string description, byte currentPeriod, IEnumerable <string> fundLines, IPeriodisedValuesLookup periodisedValues)
        {
            var fundLineGroup = new FundLineGroup($"EAS Total {ageRange} {description} Earnings Adjustment (£)", currentPeriod, FundingDataSource.EAS, fundLines, periodisedValues)
                                .WithFundLine($"EAS {ageRange} {description} Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaims })
                                .WithFundLine($"EAS {ageRange} {description} Excess Learning Support (£)", new[] { AttributeConstants.EasExcessLearningSupport });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Apprenticeship Frameworks FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrFm35FundLineGroup(string ageRange, string description, byte currentPeriod, IEnumerable <string> fundLines, IPeriodisedValuesLookup periodisedValues)
        {
            var fundLineGroup = new FundLineGroup($"ILR Total {ageRange} {description} (£)", currentPeriod, FundingDataSource.FM35, fundLines, periodisedValues)
                                .WithFundLine($"ILR {ageRange} {description} Programme Funding (£)", new[] { AttributeConstants.Fm35OnProgPayment, AttributeConstants.Fm35AchievePayment, AttributeConstants.Fm35BalancePayment, AttributeConstants.Fm35EmpOutcomePay })
                                .WithFundLine($"ILR {ageRange} {description} Learning Support (£)", new[] { AttributeConstants.Fm35LearnSuppFundCash });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Advanced Loans Bursary Budget FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrFm99FundLineGroup(byte currentPeriod, IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Advanced Loans Bursary";

            var fundLineGroup = new FundLineGroup($"ILR Total {description} (£)", currentPeriod, FundingDataSource.FM99, new[] { FundLineConstants.AdvancedLearnerLoansBursary }, periodisedValues)
                                .WithFundLine($"ILR {description} Funding (£)", new[] { AttributeConstants.Fm99AlbSupportPayment })
                                .WithFundLine($"ILR {description} Area Costs (£)", new[] { AttributeConstants.Fm99AreaUpliftBalPayment, AttributeConstants.Fm99AreaUpliftOnProgPayment });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Employers On Apprenticeship Service - Unresolved Data Locks FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrApprenticeshipsUnresolvedDataLocksFundLineGroup(byte currentPeriod, IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Apprenticeship (Employer on App Service) Unresolved Data Locks";

            var fundLineGroup = new FundLineGroup($"Total {description} (£)", currentPeriod, FundingDataSource.DAS, null, periodisedValues)
                                .WithFundLine($"ILR 16-18 {description} (£)", new[] { FundLineConstants.ApprenticeshipEmployerOnAppServiceUnresolvedDataLock1618 }, new[] { Constants.DASPayments.FundingSource.Levy, Constants.DASPayments.FundingSource.LevyTransfer }, Constants.DASPayments.TransactionType.All)
                                .WithFundLine($"ILR Adult {description} (£)", new[] { FundLineConstants.ApprenticeshipEmployerOnAppServiceUnresolvedDataLock19Plus }, new[] { Constants.DASPayments.FundingSource.Levy, Constants.DASPayments.FundingSource.LevyTransfer }, Constants.DASPayments.TransactionType.All);

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build EAS Advanced Loans Bursary Budget FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildEasFm99FundLineGroup(byte currentPeriod,
                                                        IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Advanced Loans Bursary";

            var fundLineGroup = new FundLineGroup($"EAS Total {description} Earnings Adjustment (£)", currentPeriod, FundingDataSource.EAS, new[] { FundLineConstants.AdvancedLearnerLoansBursary }, periodisedValues)
                                .WithFundLine($"EAS {description} Excess Support (£)", new[] { AttributeConstants.EasAllbExcessSupport })
                                .WithFundLine($"EAS {description} Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaims });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build EAS Employers On Apprenticeship Service - Levy FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public virtual IFundLineGroup BuildEasLevyApprenticeshipsFundLineGroup(string ageRange, string description, byte currentPeriod, IEnumerable <string> fundLines, IPeriodisedValuesLookup periodisedValues)
        {
            var fundLineGroup = new FundLineGroup($"EAS Total {ageRange} {description} Earnings Adjustment (£)", currentPeriod, FundingDataSource.EASDAS, fundLines, periodisedValues)
                                .WithFundLine($"EAS {ageRange} {description} - Training Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaimsTraining })
                                .WithFundLine($"EAS {ageRange} {description} - Additional Payments for Providers Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaimsProvider })
                                .WithFundLine($"EAS {ageRange} {description} - Additional Payments for Employers Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaimsEmployer })
                                .WithFundLine($"EAS {ageRange} {description} - Additional Payments for Apprentices Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaimsApprentice })
                                .WithFundLine($"EAS {ageRange} {description} - Excess Learning Support (£)", new[] { AttributeConstants.EasExcessLearningSupport });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Trailblazer Apprenticeships FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrTrailblazerApprenticeshipsFundLineGroup(string ageRange, byte currentPeriod, IEnumerable <string> fundLines, IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Trailblazer Apprenticeships";

            var fundLineGroup = new FundLineGroup($"ILR Total {ageRange} {description} (£)", currentPeriod, FundingDataSource.FM81, fundLines, periodisedValues)
                                .WithFundLine($"ILR {ageRange} {description} Programme Funding (Core Government Contribution, Maths and English) (£)", new[] { AttributeConstants.Fm81CoreGovContPayment, AttributeConstants.Fm81MathEngBalPayment, AttributeConstants.Fm81MathEngOnProgPayment })
                                .WithFundLine($"ILR {ageRange} {description} Employer Incentive Payments (Achievement, Small Employer, 16-18) (£)", new[] { AttributeConstants.Fm81AchPayment, AttributeConstants.Fm81SmallBusPayment, AttributeConstants.Fm81YoungAppPayment })
                                .WithFundLine($"ILR {ageRange} {description} Learning Support (£)", new[] { AttributeConstants.Fm81LearnSuppFundCash });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build EAS Traineeships Budget FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildEasFm25FundLineGroup(byte currentPeriod, IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Traineeships";

            var fundLineGroup = new FundLineGroup($"EAS Total 16-18 {description} Earnings Adjustment (£)", currentPeriod, FundingDataSource.EAS, new[] { FundLineConstants.Traineeships1618 }, periodisedValues)
                                .WithFundLine($"EAS 16-18 {description} Authorised Claims (£)", new[] { AttributeConstants.EasAuthorisedClaims })
                                .WithFundLine($"EAS 16-18 {description} Excess Learning Support (£)", new[] { AttributeConstants.EasExcessLearningSupport })
                                .WithFundLine($"EAS 16-19 {description} Vulnerable Bursary (£)", new[] { AttributeConstants.EasVulnerableBursary })
                                .WithFundLine($"EAS 16-19 {description} Free Meals (£)", new[] { AttributeConstants.EasFreeMeals })
                                .WithFundLine($"EAS 16-19 {description} Discretionary Bursary (£)", new[] { AttributeConstants.EasDiscretionaryBursary });

            return(fundLineGroup);
        }
        // -------------------------------------------------------------------------------------------------------------------------------------
        // Build ILR Non-Levy Contracted Apprenticeships FundLineGroup
        // -------------------------------------------------------------------------------------------------------------------------------------
        public IFundLineGroup BuildIlrNonLevyApprenticeshipsFundLineGroup(string ageRange, byte currentPeriod, IEnumerable <string> fundLines, IPeriodisedValuesLookup periodisedValues)
        {
            var description = "Non-Levy Contracted Apprenticeships";

            var fundLineGroup = new FundLineGroup($"ILR Total {ageRange} {description} (£)", currentPeriod, FundingDataSource.DAS, fundLines, periodisedValues)
                                .WithFundLine($"ILR {ageRange} {description} Programme Aim Funding - Government Co-investment (£)", new [] { Constants.DASPayments.FundingSource.Co_Invested_SFA }, new [] { Constants.DASPayments.TransactionType.Learning_On_Programme, Constants.DASPayments.TransactionType.Completion, Constants.DASPayments.TransactionType.Balancing })
                                .WithFundLine($"ILR {ageRange} {description} Maths & English Programme Funding (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new [] { Constants.DASPayments.TransactionType.On_Programme_Maths_and_English, Constants.DASPayments.TransactionType.BalancingMathAndEnglish })
                                .WithFundLine($"ILR {ageRange} {description} Framework Uplift (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new[] { Constants.DASPayments.TransactionType.On_Programme_16To18_Framework_Uplift, Constants.DASPayments.TransactionType.Completion_16To18_Framework_Uplift, Constants.DASPayments.TransactionType.Balancing_16To18_Framework_Uplift })
                                .WithFundLine($"ILR {ageRange} {description} Disadvantage Payments (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new[] { Constants.DASPayments.TransactionType.First_Disadvantage_Payment, Constants.DASPayments.TransactionType.Second_Disadvantage_Payment })
                                .WithFundLine($"ILR {ageRange} {description} Additional Payments for Providers (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new[] { Constants.DASPayments.TransactionType.First_16To18_Provider_Incentive, Constants.DASPayments.TransactionType.Second_16To18_Provider_Incentive })
                                .WithFundLine($"ILR {ageRange} {description} Additional Payments for Employers (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new[] { Constants.DASPayments.TransactionType.First_16To18_Employer_Incentive, Constants.DASPayments.TransactionType.Second_16To18_Employer_Incentive })
                                .WithFundLine($"ILR {ageRange} {description} Learning Support (£)", new[] { Constants.DASPayments.FundingSource.Fully_Funded_SFA }, new[] { Constants.DASPayments.TransactionType.Learning_Support });

            return(fundLineGroup);
        }
Example #11
0
        private Worksheet RenderFundLineGroup(Worksheet worksheet, FundLineGroup fundLineGroup, bool renderFundLineGroupTotal, string contractAllocationNumber)
        {
            foreach (var fundLine in fundLineGroup.FundLines)
            {
                RenderFundLine(worksheet, fundLine, contractAllocationNumber);
            }

            if (renderFundLineGroupTotal)
            {
                var row = NextRow(worksheet);
                RenderFundingSummaryReportRow(worksheet, row, fundLineGroup, contractAllocationNumber);
                ApplyStyleToRow(worksheet, row, _fundLineGroupStyle);
                ApplyFutureMonthStyleToRow(worksheet, row, fundLineGroup.CurrentPeriod);
            }

            return(worksheet);
        }