Ejemplo n.º 1
0
        public ActionResult Featured()
        {
            var model = new BrochureModel
            {
                Brochures = _brochureService.GetAll().ToList()
            };

            return(View(model));
        }
Ejemplo n.º 2
0
        public ActionResult ManageBrochure()
        {
            var model = new BrochureModel
            {
                Brochures = _brochureService.GetAll().ToList(),
                Photo     = new UploadImageModel()
            };

            return(View(model));
        }
Ejemplo n.º 3
0
 public IActionResult GetAll()
 {
     try
     {
         var result = _brochureService.GetAll();
         return(Ok(result));
     }
     catch (BusinessLogicException exception)
     {
         return(BadRequest(exception.Message));
     }
     catch (Exception exception)
     {
         _logger.LogInformation(exception.Message);
         return(StatusCode((int)HttpStatusCode.InternalServerError));
     }
 }