private static Control RowFor(AuditLogEntry entry) { var row = new HtmlGenericControl("tr"); row.Controls.Add(CellContaining(FormatDateTime(entry.Timestamp))); row.Controls.Add(CellContaining(entry.Action.ToDescriptionString())); row.Controls.Add(CellContaining(entry.Username)); row.Controls.Add(CellContaining(entry.Email)); row.Controls.Add(CellContaining(entry.Message)); return(row); }
private void AddLogEntry(JobAction action, string messageAmendment = null) { var entry = new AuditLogEntry { PluginId = PluginId, Action = action, Message = messageAmendment == null ? Reason : string.Format("{0}<br />{1}", Reason, messageAmendment) }; var store = typeof(AuditLogEntry).GetStore(); store.Save(entry); }
private static Control RowFor(AuditLogEntry entry) { var row = new HtmlGenericControl("tr"); row.Controls.Add(CellContaining(FormatDateTime(entry.Timestamp))); row.Controls.Add(CellContaining(entry.Action.ToDescriptionString())); row.Controls.Add(CellContaining(entry.Username)); row.Controls.Add(CellContaining(entry.Email)); row.Controls.Add(CellContaining(entry.Message)); return row; }