public IHttpActionResult PutContactsInfo_tbl(int id, ContactsInfo_tbl contactsInfo_tbl)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            if (id != contactsInfo_tbl.ID)
            {
                return(BadRequest());
            }

            db.Entry(contactsInfo_tbl).State = EntityState.Modified;

            try
            {
                db.SaveChanges();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!ContactsInfo_tblExists(id))
                {
                    return(NotFound());
                }
                else
                {
                    throw;
                }
            }

            return(StatusCode(HttpStatusCode.NoContent));
        }
        public IHttpActionResult GetContactsInfo_tbl(int id)
        {
            ContactsInfo_tbl contactsInfo_tbl = db.ContactsInfo_tbl.Find(id);

            if (contactsInfo_tbl == null)
            {
                return(NotFound());
            }

            return(Ok(contactsInfo_tbl));
        }
        public IHttpActionResult PostContactsInfo_tbl(ContactsInfo_tbl contactsInfo_tbl)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            db.ContactsInfo_tbl.Add(contactsInfo_tbl);
            db.SaveChanges();

            return(CreatedAtRoute("DefaultApi", new { id = contactsInfo_tbl.ID }, contactsInfo_tbl));
        }
        public IHttpActionResult DeleteContactsInfo_tbl(int id)
        {
            ContactsInfo_tbl contactsInfo_tbl = db.ContactsInfo_tbl.Find(id);

            if (contactsInfo_tbl == null)
            {
                return(NotFound());
            }

            db.ContactsInfo_tbl.Remove(contactsInfo_tbl);
            db.SaveChanges();

            return(Ok(contactsInfo_tbl));
        }