Пример #1
0
        // DELETE api/<controller>/5
        public IHttpActionResult Delete(int id)
        {
            IHttpActionResult result  = null;
            TermService       service = new TermService();

            Term term = service.GetTerm(id);

            if (term != null)
            {
                service.RemoveTerm(id);

                result = Ok(true);
            }
            else
            {
                result = NotFound();
            }

            return(result);
        }