Beispiel #1
0
 public static void Write (DateTime dateTimeUtc, int actingPersonId, PWLogItem affectedItem,
                           int affectedItemId,
                           PWLogAction actionType, string actionDescription, string comment,
                           string changedField, string valueBefore, string valueAfter)
 {
     SwarmDb.GetDatabaseForWriting().CreatePWLogEntry(dateTimeUtc, actingPersonId, affectedItem.ToString(),
                                                        affectedItemId, actionType.ToString(), actionDescription,
                                                        changedField, valueBefore, valueAfter, comment, GetCurrentIp());
 }
Beispiel #2
0
        public static BasicPWLog[] GetLatestEvents(PWLogItem affectedItemType, DateTime beforeDate, int[] affectedIds, PWLogAction[] actionTypes)
        {
            List <string> actionTypeList = new List <string>();

            foreach (var at in actionTypes)
            {
                actionTypeList.Add(at.ToString());
            }

            return(SwarmDb.GetDatabaseForReading().GetLatestEvents(affectedItemType.ToString(), beforeDate, affectedIds, actionTypeList.ToArray()));
        }
Beispiel #3
0
        private static string hostIp = ""; //Used in batch programs

        public static void Write(DateTime dateTimeUtc, int actingPersonId, PWLogItem affectedItem,
                                 int affectedItemId,
                                 PWLogAction actionType, string actionDescription, string comment,
                                 string changedField, string valueBefore, string valueAfter)
        {
            SwarmDb.GetDatabaseForWriting().CreatePWLogEntry(dateTimeUtc, actingPersonId, affectedItem.ToString(),
                                                             affectedItemId, actionType.ToString(), actionDescription,
                                                             changedField, valueBefore, valueAfter, comment, GetCurrentIp());
        }
Beispiel #4
0
 public static DateTime CheckLatest(PWLogItem affectedItemType, int affectedItemId, PWLogAction actionType)
 {
     return(SwarmDb.GetDatabaseForReading()
            .CheckLogEntry(affectedItemType.ToString(), affectedItemId, actionType.ToString()));
 }
Beispiel #5
0
        public static BasicPWLog[] GetLatestEvents (PWLogItem affectedItemType, DateTime beforeDate, int[] affectedIds, PWLogAction[] actionTypes)
        {

            List<string> actionTypeList = new List<string>();
            foreach (var at in actionTypes)
                actionTypeList.Add(at.ToString());

            return SwarmDb.GetDatabaseForReading().GetLatestEvents(affectedItemType.ToString(), beforeDate, affectedIds, actionTypeList.ToArray());
        }
Beispiel #6
0
 public static DateTime CheckLatest (PWLogItem affectedItemType, int affectedItemId, PWLogAction actionType)
 {
     return SwarmDb.GetDatabaseForReading().CheckLogEntry(affectedItemType.ToString(), affectedItemId, actionType.ToString());
 }