public void LogAction(ApplicationUser user, ApplicationModule module, string action, string details, string performedAt)
 {
     LogAction(user, module, action, 0, details, string.Empty);
 }
 public void LogAction(ApplicationUser user, ApplicationModule module, string action, int referenceId, string details, string performedAt)
 {
     var machineIpOrHostName = (string.IsNullOrEmpty(performedAt) ? Environment.MachineName : performedAt);
     var userAction = (!UserActions.IsValidAction(action) ? UserActions.Unknown : action);
     AuditLogs.Add(new AuditLog()
     {
         Action = userAction,
         ApplicationModuleId = module.ApplicationModuleId,
         UserId = user.UserId,
         ReferenceId = referenceId,
         Details = details,
         PerformedAt = machineIpOrHostName
     });
 }
 public void LogAction(ApplicationUser user, ApplicationModule module, string action, int referenceId, string details)
 {
     LogAction(user, module, action, referenceId, details, string.Empty);
 }