public ActionResult Delete(int id)
 {
     idepartmentBusiness.DeleteDepartment(id);
     return(Json(new
     {
         success = true
     }));
     // return RedirectToAction("Index");
 }
Exemplo n.º 2
0
        public string DeleteDepartment(string Code)
        {
            try
            {
                object result = null;

                result = _departmentBusiness.DeleteDepartment(Code);
                return(JsonConvert.SerializeObject(new { Result = "OK", Message = result }));
            }
            catch (Exception ex)
            {
                AppConstMessage cm = c.GetMessage(ex.Message);
                return(JsonConvert.SerializeObject(new { Result = "ERROR", Message = cm.Message }));
            }
        }