Esempio n. 1
0
        public JsonResult DeleteData(int? id)
        {
            if (id > 0)
            {
                db.Delete(id.Value);
                return Json("success", JsonRequestBehavior.AllowGet);
            }

            return Json("error", JsonRequestBehavior.DenyGet);
        }
Esempio n. 2
0
 public void delete(DeletePatientRequest request)
 {
     try
     {
         var response = new DeletePatientResponse();
         var bc       = new PatientComponent();
         bc.Delete(request.Id);
     }
     catch (Exception ex)
     {
         var httpError = new HttpResponseMessage()
         {
             StatusCode   = (HttpStatusCode)422,
             ReasonPhrase = ex.Message
         };
         throw new HttpResponseException(httpError);
     }
 }
Esempio n. 3
0
 public void Delete(int id)
 {
     bs.Delete(id);
 }