Exemple #1
0
        public IActionResult ModifyDeparture(int id, [FromBody] Departure departure)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest() as IActionResult);
            }
            var entity = service.UpdateDepartureInfo(departure);

            return(entity == null?StatusCode(304) as IActionResult : Ok(entity));
        }