Exemplo n.º 1
0
        public static void LogException(string message)
        {
            var entry = new SiteLogEntry();

            entry.Message           = message;
            entry.SiteLogTypeID     = (int)SiteLogType.Exception;
            entry.SiteLogCategoryID = (int)SiteLogCategoryType.GeneralException;
            LogSiteEntry(entry);
        }
Exemplo n.º 2
0
        // going away...shouldn't be in use anywhere

        public static void LogNonProviderEvent(string message)
        {
            var entry = new SiteLogEntry();

            entry.Message           = message;
            entry.SiteLogTypeID     = (int)SiteLogType.General;
            entry.SiteLogCategoryID = (int)SiteLogCategoryType.GeneralAppEvent;
            entry.ApplicationID     = 0;
            LogNonProviderEvent(entry);
        }
Exemplo n.º 3
0
        public static void LogAnalyticsMessage(string message)
        {
            var entry = new SiteLogEntry();

            entry.Message           = message;
            entry.SiteLogTypeID     = (int)SiteLogType.General;
            entry.SiteLogCategoryID = (int)SiteLogCategoryType.AnalyticsMessage;
            entry.ApplicationID     = 0;
            LogSiteEntry(entry);
        }
Exemplo n.º 4
0
        public static void LogAddonPackException(string message)
        {
            var entry = new SiteLogEntry();

            entry.Message           = message;
            entry.SiteLogTypeID     = (int)SiteLogType.Exception;
            entry.SiteLogCategoryID = (int)SiteLogCategoryType.AddonPackException;
            entry.ApplicationID     = 0;
            LogSiteEntry(entry);
        }
Exemplo n.º 5
0
        public static void LogSearchException(int docID, string docTitle, string message)
        {
            var entry = new SiteLogEntry();

            entry.Message           = "ContentID and Title: " + docID + " : " + docTitle + " ERROR: " + message;
            entry.SiteLogTypeID     = (int)SiteLogType.Exception;
            entry.SiteLogCategoryID = (int)SiteLogCategoryType.SearchException;
            entry.ApplicationID     = 0;
            LogSiteEntry(entry);
        }
Exemplo n.º 6
0
        public static void LogSiteEntry(SiteLogType logType, SiteLogCategoryType categoryType, string message, int applicationID)
        {
            var entry = new SiteLogEntry();

            entry.Message           = message;
            entry.SiteLogTypeID     = (int)logType;
            entry.SiteLogCategoryID = (int)categoryType;
            entry.ApplicationID     = applicationID;
            LogSiteEntry(entry);
        }
Exemplo n.º 7
0
        public static void LogNonProviderEvent(SiteLogEntry siteLogEntry)
        {
            using (var cn = new SqlConnection(ConfigurationManager.ConnectionStrings["SueetieConnectionString"].ConnectionString))
            {
                using (var cmd = new SqlCommand("Sueetie_SiteLog_Add", cn))
                {
                    cmd.CommandType = CommandType.StoredProcedure;

                    cmd.Parameters.Add("@SiteLogTypeID", SqlDbType.Int, 4).Value     = siteLogEntry.SiteLogTypeID;
                    cmd.Parameters.Add("@SiteLogCategoryID", SqlDbType.Int, 4).Value = siteLogEntry.SiteLogCategoryID;
                    cmd.Parameters.Add("@ApplicationID", SqlDbType.Int, 4).Value     = siteLogEntry.ApplicationID;
                    cmd.Parameters.Add("@Message", SqlDbType.NText).Value            = siteLogEntry.Message;

                    cn.Open();
                    cmd.ExecuteNonQuery();
                    cn.Close();
                }
            }
        }
Exemplo n.º 8
0
 public static void LogSiteEntry(SiteLogEntry entry)
 {
     SueetieCommon.CreateSiteLogEntry(entry);
 }
Exemplo n.º 9
0
        public static List <SiteLogEntry> GetSiteLogEntryList(SiteLogEntry siteLogEntry)
        {
            var provider = SueetieDataProvider.LoadProvider();

            return(provider.GetSiteLogEntryList(siteLogEntry));
        }
Exemplo n.º 10
0
        public static void CreateSiteLogEntry(SiteLogEntry siteLogEntry)
        {
            var provider = SueetieDataProvider.LoadProvider();

            provider.CreateSiteLogEntry(siteLogEntry);
        }