private bool AnnotationExisting(Guid id, string messageType)
        {
            var annotation = _annotationRepository.GetById(id);

            if (annotation != null)
            {
                return(true);
            }

            _mediator.RaiseEvent(new DomainNotification(messageType, "Annotation not found"));
            return(false);
        }
Пример #2
0
 public AnnotationViewModel GetById(Guid id)
 {
     return(_mapper.Map <AnnotationViewModel>(_annotationRepository.GetById(id)));
 }
 public IEnumerable <AnnotationViewModel> Get(Guid id)
 {
     return(_mapper.Map <IEnumerable <AnnotationViewModel> >(_annotationRepository.GetById(id)));
 }