Beispiel #1
0
        // GET: EstadoModels/Details/5
        public async Task <IActionResult> Details(int?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var estadoModel = await _repositoryEstado.GetAsync(id);

            if (estadoModel == null)
            {
                return(NotFound());
            }

            return(View(estadoModel));
        }
        // GET: CidadeModels/Details/5
        public async Task <IActionResult> Details(int?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var lojaModel = await _repositoryLoja.GetAsync(id.Value);

            ViewData["ShoppingId"] = new SelectList(_repositoryShopping.GetAll(), "ShoppingId", "Nome");

            if (lojaModel == null)
            {
                return(NotFound());
            }

            return(View(lojaModel));
        }
        // GET: CidadeModels/Details/5
        public async Task <IActionResult> Details(int?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var cidadeModel = await _repositoryCidade.GetAsync(id.Value);

            ViewData["EstadoId"] = new SelectList(_repositoryEstado.GetAll(), "EstadoId", "Nome");

            if (cidadeModel == null)
            {
                return(NotFound());
            }

            return(View(cidadeModel));
        }
Beispiel #4
0
        // GET: ShoppingModels/Details/5
        public async Task <IActionResult> Details(int?id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var shoppingModel = await _repositoryShopping.GetAsync(id.Value);

            ViewData["EnderecoId"] = new SelectList(_repositoryEndereco.GetAll(), "EnderecoId", "Rua");

            if (shoppingModel == null)
            {
                return(NotFound());
            }

            return(View(shoppingModel));
        }