Esempio n. 1
0
        public Customer UpDate(UpDateCustomerOptions opt)
        {
            if (opt == null)
            {
                return(null);
            }
            var customer = SearchCustomers(new CustomerOptions()
            {
                CustomerId = opt.CustomerId,
            }).SingleOrDefault();

            if (customer != null)
            {
                customer.FirstName = opt.FirstName;
                customer.LastName  = opt.LastName;
                customer.IsActive  = false;
            }

            return(customer);
        }
Esempio n. 2
0
        public IActionResult Update(UpDateCustomerOptions opt)
        {
            var result = customerService_.UpDate(opt);

            return(Json(result));
        }