public override async Task <CriterionsResponse> GetAllCriteria(EvaluationEmpty request, ServerCallContext context)
        {
            try
            {
                var response = await _evaluation.GetAllCriterions();

                if (response is null || response.Count() == 0)
                {
                    throw new Exception("EvaluationR - GetCriteria");
                }
                var criterions = new List <CriterionAdd>();
                response.ToList().ForEach((criterion) =>
                {
                    var criterionAdd = _mapper.Map <EvaluationCriterion, CriterionAdd>(criterion);
                    criterions.Add(criterionAdd);
                });
                return(new CriterionsResponse()
                {
                    Criterions = { criterions }
                });
            }
            catch (Exception e)
            {
                _logger.LogError(e, "ERROR");
                return(new CriterionsResponse()
                {
                });
            }
        }
        public override async Task <MarksResponse> GetAllMarks(EvaluationEmpty request, ServerCallContext context)
        {
            try
            {
                var response = await _evaluation.GetAllMarks();

                if (response is null || response.Count() == 0)
                {
                    throw new Exception("EvaluationR - GetMarks");
                }
                var marks = new List <MarkAdd>();
                response.ToList().ForEach((mark) =>
                {
                    var markAdd = _mapper.Map <Mark, MarkAdd>(mark);
                    marks.Add(markAdd);
                });
                return(new MarksResponse()
                {
                    Marks = { marks }
                });
            }
            catch (Exception e)
            {
                _logger.LogError(e, "ERROR");
                return(new MarksResponse()
                {
                });
            }
        }
        public override async Task <EvaluationsResponse> GetAllEvaluations(EvaluationEmpty request, ServerCallContext context)
        {
            try
            {
                var response = await _evaluation.GetAllEvalutions();

                if (response is null || response.Count() == 0)
                {
                    throw new Exception("EvaluationR - GetEvaluations");
                }
                var evaluationsAdd = new List <EvaluationAdd>();
                response.ToList().ForEach((evaluation) =>
                {
                    var evaluationAdd = _mapper.Map <Evaluation2, EvaluationAdd>(evaluation);
                    evaluationsAdd.Add(evaluationAdd);
                });
                return(new EvaluationsResponse()
                {
                    Evaluations = { evaluationsAdd }
                });
            }
            catch (Exception e)
            {
                _logger.LogError(e, "ERROR");
                return(new EvaluationsResponse()
                {
                });
            }
        }