public static void LogAudit(
string actionType,
string message,
string accountId,
string username,
string objectId,
Dictionary<string, object> details)
{
if (HttpContext.Current == null)
{
return;
}
if (HttpContext.Current.Application["AuditLogPowerSwitch"] != null)
{
bool auditLogPowerSwitch;
if (bool.TryParse(HttpContext.Current.Application["AuditLogPowerSwitch"].ToString().ToLower(), out auditLogPowerSwitch))
{
if (auditLogPowerSwitch)
{
WebBaseAuditLogger.CreateAuditLog("Atomia Order Page", actionType, message, accountId, username, objectId, details);
}
}
}
}