Exemple #1
0
        public string Evaluate(Learner learner)
        {
            if (learner?.LearningDeliveries == null)
            {
                return("N");
            }

            var allowedLARSCategoryRefs = _referenceData.Get(AppConstants.DD29LARSCategoryRef).Split(',').ToList();

            foreach (var learningDelivery in learner.LearningDeliveries)
            {
                var larsResult = _larsExternalData.Get(learningDelivery.LearnAimRef) ?? new List <string>();

                if (learningDelivery.ProgType == _referenceData.Get(AppConstants.DD29LearningDeliveryProgType) &&
                    larsResult.Intersect(allowedLARSCategoryRefs).Any())
                {
                    return("Y");
                }
            }

            return("N");
        }
Exemple #2
0
        public bool Evaluate(LearningDelivery objectToValidate)
        {
            var larsResult = _LARSNotionalNVQLevelData.Get(objectToValidate.LearnAimRef);

            return(larsResult != null && larsResult.Intersect(_AllowedLARSNotionalNVQLevelv2).Any());
        }