Пример #1
0
        public void BuildLARSFrameworkApprenticeshipFunding()
        {
            var larsFAP = new LARSFrameworkApprenticeshipFunding
            {
                SixteenToEighteenEmployerAdditionalPayment = 1.0m,
                SixteenToEighteenProviderAdditionalPayment = 2.0m,
                SixteenToEighteenFrameworkUplift           = 3.0m,
                CareLeaverAdditionalPayment = 4.0m,
                EffectiveFrom      = new DateTime(2019, 8, 1),
                FundingCategory    = "Type",
                MaxEmployerLevyCap = 5.0m,
                ReservedValue2     = 6.0m,
                ReservedValue3     = 7.0m
            };

            var dataEntity = NewService().BuildLARSFrameworkApprenticeshipFunding(larsFAP);

            dataEntity.EntityName.Should().Be("Framework_LARS_ApprenticshipFunding");
            dataEntity.Attributes.Should().HaveCount(10);
            dataEntity.Attributes["FrameworkAF1618EmployerAdditionalPayment"].Value.Should().Be(larsFAP.SixteenToEighteenEmployerAdditionalPayment);
            dataEntity.Attributes["FrameworkAF1618ProviderAdditionalPayment"].Value.Should().Be(larsFAP.SixteenToEighteenProviderAdditionalPayment);
            dataEntity.Attributes["FrameworkAF1618FrameworkUplift"].Value.Should().Be(larsFAP.SixteenToEighteenFrameworkUplift);
            dataEntity.Attributes["FrameworkAFCareLeaverAdditionalPayment"].Value.Should().Be(larsFAP.CareLeaverAdditionalPayment);
            dataEntity.Attributes["FrameworkAFEffectiveFrom"].Value.Should().Be(larsFAP.EffectiveFrom);
            dataEntity.Attributes["FrameworkAFEffectiveTo"].Value.Should().Be(larsFAP.EffectiveTo);
            dataEntity.Attributes["FrameworkAFFundingCategory"].Value.Should().Be(larsFAP.FundingCategory);
            dataEntity.Attributes["FrameworkAFMaxEmployerLevyCap"].Value.Should().Be(larsFAP.MaxEmployerLevyCap);
            dataEntity.Attributes["FrameworkAFReservedValue2"].Value.Should().Be(larsFAP.ReservedValue2);
            dataEntity.Attributes["FrameworkAFReservedValue3"].Value.Should().Be(larsFAP.ReservedValue3);
        }
 public IDataEntity BuildLARSFrameworkApprenticeshipFunding(LARSFrameworkApprenticeshipFunding larsFrameworkApprenticeshipFunding)
 {
     return(new DataEntity(Attributes.EntityFrameworkLARSApprenticshipFunding)
     {
         Attributes = new Dictionary <string, IAttributeData>()
         {
             { Attributes.FrameworkAF1618EmployerAdditionalPayment, new AttributeData(larsFrameworkApprenticeshipFunding.SixteenToEighteenEmployerAdditionalPayment) },
             { Attributes.FrameworkAF1618ProviderAdditionalPayment, new AttributeData(larsFrameworkApprenticeshipFunding.SixteenToEighteenProviderAdditionalPayment) },
             { Attributes.FrameworkAF1618FrameworkUplift, new AttributeData(larsFrameworkApprenticeshipFunding.SixteenToEighteenFrameworkUplift) },
             { Attributes.FrameworkAFCareLeaverAdditionalPayment, new AttributeData(larsFrameworkApprenticeshipFunding.CareLeaverAdditionalPayment) },
             { Attributes.FrameworkAFEffectiveFrom, new AttributeData(larsFrameworkApprenticeshipFunding.EffectiveFrom) },
             { Attributes.FrameworkAFEffectiveTo, new AttributeData(larsFrameworkApprenticeshipFunding.EffectiveTo) },
             { Attributes.FrameworkAFFundingCategory, new AttributeData(larsFrameworkApprenticeshipFunding.FundingCategory) },
             { Attributes.FrameworkAFMaxEmployerLevyCap, new AttributeData(larsFrameworkApprenticeshipFunding.MaxEmployerLevyCap) },
             { Attributes.FrameworkAFReservedValue2, new AttributeData(larsFrameworkApprenticeshipFunding.ReservedValue2) },
             { Attributes.FrameworkAFReservedValue3, new AttributeData(larsFrameworkApprenticeshipFunding.ReservedValue3) }
         }
     });
 }
Пример #3
0
 private Data.External.LARS.Model.LARSFrameworkApprenticeshipFunding LARSFrameworkApprenticeshipFundingFromEntity(LARSFrameworkApprenticeshipFunding entity)
 {
     return(new Data.External.LARS.Model.LARSFrameworkApprenticeshipFunding
     {
         BandNumber = entity.BandNumber,
         CareLeaverAdditionalPayment = entity.CareLeaverAdditionalPayment,
         FundingCategory = entity.FundingCategory,
         EffectiveFrom = entity.EffectiveFrom,
         EffectiveTo = entity.EffectiveTo,
         CoreGovContributionCap = entity.CoreGovContributionCap,
         SixteenToEighteenIncentive = entity.SixteenToEighteenIncentive,
         SixteenToEighteenProviderAdditionalPayment = entity.SixteenToEighteenProviderAdditionalPayment,
         SixteenToEighteenEmployerAdditionalPayment = entity.SixteenToEighteenEmployerAdditionalPayment,
         SixteenToEighteenFrameworkUplift = entity.SixteenToEighteenFrameworkUplift,
         Duration = entity.Duration,
         ReservedValue2 = entity.ReservedValue2,
         ReservedValue3 = entity.ReservedValue3,
         MaxEmployerLevyCap = entity.MaxEmployerLevyCap,
         FundableWithoutEmployer = entity.FundableWithoutEmployer
     });
 }