Ejemplo n.º 1
0
 public static void AddSupportSessionLog(SupportSessionLog log)
 {
     lock (supportSessionLogLock)
     {
         supportSessionLogs.Add(log);
     }
 }
Ejemplo n.º 2
0
 public SupportSessionLog Add(SupportSessionLog supportSessionLog, int callerId)
 {
     using (UBContext ubc = new UBContext())
     {
         try
         {
             ubc.Add(supportSessionLog);
             ubc.SaveChanges();
             return(supportSessionLog);
         }
         catch (Exception ex)
         {
             if (ex.InnerException != null)
             {
                 Utils.Logging.AddLog(new SystemLog()
                 {
                     LoggerName = "Unifiedban.Data",
                     Date       = DateTime.Now,
                     Function   = "Unifiedban.Data.SupportSessionLogService.Add",
                     Level      = SystemLog.Levels.Warn,
                     Message    = ex.InnerException.Message,
                     UserId     = callerId
                 });
             }
         }
         return(null);
     }
 }