コード例 #1
0
        public IActionResult Update(string id, [FromBody] Customer req)
        {
            if (req == null)
            {
                return(BadRequest());
            }
            var userbyId = _posrepo.GetCustomerById(id);

            Mapper.Map(req, userbyId);
            _posrepo.UpdateCustomer(userbyId);

            return(StatusCode(204));
        }