public ActionResult DeletePort(int portId) { #region Check Rights bool hasRights = false; hasRights = AdminHelper.CheckUserAction(ScreenEnum.PortsLibrary, ActionEnum.Delete); if (!hasRights) { return(Json("You are UnAuthorized to do this action")); } #endregion string isDeleted = LibraryCommonHelper.DeletePort(portId); return(Json(isDeleted)); }