示例#1
0
        public IActionResult Edit(int id, CustomerViewModel customerViewModel)
        {
            if (ModelState.IsValid)
            {
                var customer = Map(customerViewModel);
                customer.CustomerId = id;
                _billingContext.UpdateCustomer(id, customer);

                return(Redirect("Index"));
            }
            return(View(customerViewModel));
        }