public Standard MapToStandard(StandardSearchResultsItem document)
 {
     return(new Standard
     {
         StandardId = document.StandardId,
         Title = document.Title,
         StandardPdf = document.StandardPdf,
         AssessmentPlanPdf = document.AssessmentPlanPdf,
         Level = document.Level,
         IsPublished = document.Published,
         JobRoles = document.JobRoles,
         Keywords = document.Keywords,
         Duration = document.Duration,
         MaxFunding = document.FundingCap,
         TypicalLength = new TypicalLength {
             From = document.Duration, To = document.Duration, Unit = "m"
         },
         IntroductoryText = document.IntroductoryText,
         EntryRequirements = document.EntryRequirements,
         WhatApprenticesWillLearn = document.WhatApprenticesWillLearn,
         Qualifications = document.Qualifications,
         ProfessionalRegistration = document.ProfessionalRegistration,
         OverviewOfRole = document.OverviewOfRole
     });
 }
Beispiel #2
0
 public Standard MapToStandard(StandardSearchResultsItem document)
 {
     return(new Standard
     {
         StandardId = document.StandardId.ToString(),
         Title = document.Title,
         StandardPdf = document.StandardPdf,
         AssessmentPlanPdf = document.AssessmentPlanPdf,
         Level = document.Level,
         IsPublished = document.Published,
         JobRoles = document.JobRoles,
         Keywords = document.Keywords,
         Duration = document.Duration,
         FundingPeriods = document.FundingPeriods,
         CurrentFundingBand = _fundingCapCalculator.CalculateCurrentFundingBand(document),
         TypicalLength = new TypicalLength {
             From = document.Duration, To = document.Duration, Unit = "m"
         },
         IntroductoryText = document.IntroductoryText,
         EntryRequirements = document.EntryRequirements,
         WhatApprenticesWillLearn = document.WhatApprenticesWillLearn,
         Qualifications = document.Qualifications,
         ProfessionalRegistration = document.ProfessionalRegistration,
         OverviewOfRole = document.OverviewOfRole,
         Ssa1 = document.SectorSubjectAreaTier1,
         Ssa2 = document.SectorSubjectAreaTier2,
         StandardSectorCode = document.StandardSectorCode,
         EffectiveFrom = document.EffectiveFrom,
         EffectiveTo = document.EffectiveTo,
         IsActiveStandard = _activeApprenticeshipChecker.CheckActiveStandard(document.StandardId.ToString(), document.EffectiveFrom, document.EffectiveTo),
         LastDateForNewStarts = document.LastDateForNewStarts,
         RegulatedStandard = document.RegulatedStandard
     });
 }
 public StandardSummary MapToStandardSummary(StandardSearchResultsItem document)
 {
     return(new StandardSummary
     {
         Id = document.StandardId,
         Title = document.Title,
         Level = document.Level,
         IsPublished = document.Published,
         Duration = document.Duration,
         MaxFunding = document.FundingCap,
         TypicalLength = new TypicalLength {
             From = document.Duration, To = document.Duration, Unit = "m"
         },
     });
 }
 public Standard MapToStandard(StandardSearchResultsItem document)
 {
     return(new Standard
     {
         StandardId = document.StandardId,
         Title = document.Title,
         Level = document.Level,
         IsPublished = document.Published,
         JobRoles = document.JobRoles,
         Keywords = document.Keywords,
         Duration = document.Duration,
         IntroductoryText = document.IntroductoryText,
         EntryRequirements = document.EntryRequirements,
         WhatApprenticesWillLearn = document.WhatApprenticesWillLearn,
         Qualifications = document.Qualifications,
         ProfessionalRegistration = document.ProfessionalRegistration,
         OverviewOfRole = document.OverviewOfRole,
         EffectiveFrom = document.EffectiveFrom,
         EffectiveTo = document.EffectiveTo
     });
 }
Beispiel #5
0
 public StandardSummary MapToStandardSummary(StandardSearchResultsItem document)
 {
     return(new StandardSummary
     {
         Id = document.StandardId.ToString(),
         Title = document.Title,
         Level = document.Level,
         StandardSectorCode = document.StandardSectorCode,
         IsPublished = document.Published,
         Duration = document.Duration,
         FundingPeriods = document.FundingPeriods,
         CurrentFundingCap = _fundingCapCalculator.CalculateCurrentFundingBand(document),
         TypicalLength = new TypicalLength {
             From = document.Duration, To = document.Duration, Unit = "m"
         },
         Ssa1 = document.SectorSubjectAreaTier1,
         Ssa2 = document.SectorSubjectAreaTier2,
         EffectiveFrom = document.EffectiveFrom,
         EffectiveTo = document.EffectiveTo,
         IsActiveStandard = _activeApprenticeshipChecker.CheckActiveStandard(document.StandardId.ToString(), document.EffectiveFrom, document.EffectiveTo),
         LastDateForNewStarts = document.LastDateForNewStarts,
         RegulatedStandard = document.RegulatedStandard
     });
 }
Beispiel #6
0
 public int CalculateCurrentFundingBand(StandardSearchResultsItem standard)
 {
     return(_activeApprenticeshipChecker.CheckActiveStandard(standard.StandardId.ToString(), standard.EffectiveFrom, standard.EffectiveTo) ? GetFundingCapFromPeriods(standard.FundingPeriods) : 0);
 }