public DtoZoneListItem AddNewZone(DtoCreateZone zone) { var created = zoneRepository.Insert(new Zone() { Name = zone.Name }); return(ZoneToDtoZone(created)); }
public ActionResult <DtoCreateZone> Create([FromBody] DtoCreateZone value) { var created = zoneManager.AddNewZone(value); if (created != null) { return(Ok(created)); } return(BadRequest()); }
protected void ClearCreateZone() { createZone = new DtoCreateZone(); }