public ActionResult Edit(AdminAddressViewModel address)
        {
            if (ModelState.IsValid)
            {
                this.addressService.Update(address.Id, address.City, address.Neighbour);

                return RedirectToAction("Index");
            }

            return View(address);
        }
Exemplo n.º 2
0
        public ActionResult Edit(AdminAddressViewModel address)
        {
            if (ModelState.IsValid)
            {
                this.addressService.Update(address.Id, address.City, address.Neighbour);

                return(RedirectToAction("Index"));
            }

            return(View(address));
        }
        public ActionResult Create([DataSourceRequest]DataSourceRequest request, AdminAddressViewModel model)
        {
            addressService.Create(model.City, model.Neighbour);

            return View(model);
        }
Exemplo n.º 4
0
        public ActionResult Create([DataSourceRequest] DataSourceRequest request, AdminAddressViewModel model)
        {
            addressService.Create(model.City, model.Neighbour);

            return(View(model));
        }