Beispiel #1
0
        public IActionResult CreateGift([FromBody] GiftEntity giftEntity)
        {
            giftEntity.CreationDate = DateTime.Now;
            _giftRepository.CreateGift(giftEntity);
            if (!_giftRepository.Save())
            {
                return(StatusCode(500, "A problem happened while handling your request"));
            }

            return(NoContent());
        }