public void Delete(int id) { if (id == EntityId) { htmltext.DeleteHtmlText(id); } }
public void Delete(int id) { if (AuthEntityId(EntityNames.Module) == id) { _htmlText.DeleteHtmlText(id); _logger.Log(LogLevel.Information, this, LogFunction.Delete, "Html/Text Deleted {HtmlTextId}", id); } else { _logger.Log(LogLevel.Error, this, LogFunction.Security, "Unauthorized HtmlText Delete Attempt {ModuleId}", id); HttpContext.Response.StatusCode = (int)HttpStatusCode.Forbidden; } }
public void Delete(int id) { try { if (id == _entityId) { _htmlText.DeleteHtmlText(id); _logger.Log(LogLevel.Information, this, LogFunction.Delete, "Html/Text Deleted {HtmlTextId}", id); } } catch (Exception ex) { _logger.Log(LogLevel.Error, this, LogFunction.Delete, ex, "Delete Error {Error}", ex.Message); throw; } }
public void Delete(int id) { htmltext.DeleteHtmlText(id); }