public IActionResult Post([FromBody] TAdressen adressen) { if (adressen is null) { return(BadRequest("Adresse is null.")); } if (!ModelState.IsValid) { return(BadRequest()); } _dataRepository.Add(adressen); return(CreatedAtRoute("GetAdresse", new { Id = adressen.AdrAdresse }, null)); }
public IActionResult Post([FromBody] TBeguenstigte beg) { if (beg is null) { return(BadRequest("Beguenstigte is null.")); } if (!ModelState.IsValid) { return(BadRequest()); } _dataRepository.Add(beg); return(CreatedAtRoute("GetBeg", new { Id = beg.BegBeguenstigter }, null)); }
public IActionResult Post([FromBody] TZusagen zusagen) { if (zusagen is null) { return(BadRequest("Zusagen is null.")); } if (!ModelState.IsValid) { return(BadRequest()); } _dataRepository.Add(zusagen); return(CreatedAtRoute("GetZusagen", new { Id = zusagen.ZusZusage }, null)); }