Beispiel #1
0
        public async Task <ActionResult> Get()
        {
            try
            {
                var result = await _repository.GetEmailTemplates();

                if (result == null)
                {
                    return(NotFound());
                }

                return(Ok(result));
            }
            catch (Exception ex)
            {
                throw new JsonException(ex.Message, ex);
            }
        }
 public IEnumerable <EmailTemplate> GetEmailTemplates()
 {
     return(_emailTemplateRepository.GetEmailTemplates());
 }