コード例 #1
0
        public IActionResult Edit(Guid id)
        {
            if (id == null)
            {
                return(NotFound());
            }

            var estate = _estateService.GetEstateById(id);

            if (estate == null)
            {
                return(NotFound());
            }
            ViewData["OwnerId"] = new SelectList(_context.Owners, "OwnerId", "LastName", estate.OwnerId);
            return(View(estate));
        }