Beispiel #1
0
        public ActionResult Put(int id, [FromBody] Cat_Atomos value)
        {
            if (id != value.Id_Atomo)
            {
                return(BadRequest());
            }

            context.Entry(value).State = EntityState.Modified;
            context.SaveChanges();
            return(Ok());
        }
Beispiel #2
0
 public ActionResult Post([FromBody] Cat_Atomos atomo)
 {
     context.Cat_Atomos.Add(atomo);
     context.SaveChanges();
     return(Ok());
 }