Exemplo n.º 1
0
        public IActionResult Details(int id)
        {
            IActionResult result = null;

            try
            {
                var good = _goodsService.GetById(id);
                result = PartialView("Details", _goodsService.GetById(id));
            }
            catch (Exception ex)
            {
                result = new ContentResult();
                ((ContentResult)result).Content = "Good not found!";
            }

            return(result);
        }