コード例 #1
0
 public async Task <ActionResult <Customer> > Post([FromBody] Customer model)
 {
     return(await _customerRepo.AddNew(model));
 }
コード例 #2
0
        public async Task <IActionResult> Create(Customer customer)
        {
            await _customerRepository.AddNew(customer);

            return(RedirectToAction(nameof(Index)));
        }