Beispiel #1
0
 public IActionResult Put(Aktuel aktuel)
 {
     try
     {
         _repo.Update(aktuel);
         return(Ok(aktuel));
     }
     catch
     {
     }
     return(BadRequest());
 }
Beispiel #2
0
 public IActionResult Post([FromBody] Aktuel aktuel)
 {
     try
     {
         _repo.Add(aktuel);
         return(new StatusCodeResult(201));
     }
     catch
     {
     }
     return(BadRequest());
 }