public HttpResponseMessage PutGeslacht(ADGeslacht model) { if (model != null) { db.ADGeslachts.AddOrUpdate(model); db.SaveChanges(); } return(new HttpResponseMessage(HttpStatusCode.OK)); }
public HttpResponseMessage PostGeslacht(ADGeslacht model) { if (model != null) { db.ADGeslachts.AddOrUpdate(model); db.SaveChanges(); return(Response(HttpStatusCode.OK, "OK")); } else { return(Response(HttpStatusCode.BadRequest, "Incorrect data was provided")); } }