public Scale(TestEntity testEntity, ScaleEntity scaleEntity)
        {
            Id   = scaleEntity.Id;
            Name = scaleEntity.Name;


            var allResultEntities = testEntity.GetResults()
                                    .Where(re => re.ScaleId == scaleEntity.Id)
                                    .OrderByDescending(re => re.Points);

            InitGroupsResults(allResultEntities);
        }
        public EvaluationMapEntity ToEntity(ProfessionalQualitiesDbContext dbContext,
                                            TestEntity testEntity, ScaleEntity scaleEntity)
        {
            var entity = new EvaluationMapEntity
            {
                Test            = testEntity,
                Scale           = scaleEntity,
                LowerRangeValue = LowerRangeValue,
                UpperRangeValue = UpperRangeValue,
                Result          = Result
            };

            dbContext.EvaluationMaps.Add(entity);

            return(entity);
        }