public ActionResult Pedidos() { var userId = new Guid(User.FindFirstValue(ClaimTypes.NameIdentifier)); var vendas = _vendaService.GetByCustomer(userId); if (vendas == null) { return(NotFound()); } ViewBag.Status = StatusVenda.GetStatusVenda(); ViewBag.FormaPagamento = FormaPagamento.GetFormaPagamento(); return(View(Mapper.Map <IEnumerable <Venda>, IEnumerable <VendaViewModel> >(vendas))); }