Пример #1
0
        // GET: MarcasController/Details/5
        public ActionResult Details(int id)
        {
            var marca          = _marcaApp.GetById(id);
            var marcaViewModel = _mapper.Map <Marca, MarcaViewModel>(marca);

            return(View(marcaViewModel));
        }
Пример #2
0
        public IActionResult GetById(Guid id)
        {
            var marca = _marcaAppService.GetById(id);

            if (marca == null)
            {
                return(NotFound("Marca not found"));
            }

            return(ResponseOk(marca));
        }