Exemple #1
0
        public IActionResult Carrinho(string codigo)
        {
            if (!string.IsNullOrEmpty(codigo))
            {
                PedidoRepository.AddItem(codigo);
            }
            List <ItemPedido> itens = PedidoRepository.GetPedido().Itens;

            CarrinhoViewModel carrinhoViewModel = new CarrinhoViewModel(itens);

            return(View(carrinhoViewModel));
        }