Esempio n. 1
0
        // GET: Application/Edit/5
        public ActionResult Edit(int?id)
        {
            try
            {
                if (id == null)
                {
                    return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
                }

                RegionViewModel regionViewModel = new RegionViewModel();
                var             region          = regionViewModel.FindRegion(id);
                //TempData["ProjectId"] = appVersion.Id;
                if (region == null)
                {
                    return(HttpNotFound());
                }

                return(View(region));
            }
            catch (Exception ex)
            {
                errorlogviewmodel = new ErrorLogViewModel();
                errorlogviewmodel.LogError(ex);
                return(View("Error"));
            }
        }
Esempio n. 2
0
        // GET: Application/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }

            RegionViewModel regionViewModel = new RegionViewModel();
            var             region          = regionViewModel.FindRegion(id);

            if (region == null)
            {
                return(HttpNotFound());
            }
            return(View(region));
        }