protected override void SaveObjectToStore(AuditLogSearchBase searchBase)
        {
            MailboxAuditLogSearch mailboxAuditLogSearch = (MailboxAuditLogSearch)searchBase;

            using (MailboxAuditLogSearchItem mailboxAuditLogSearchItem = new MailboxAuditLogSearchItem(base.MailboxSession, base.Folder))
            {
                Guid guid = ((AuditLogSearchId)mailboxAuditLogSearch.Identity).Guid;
                mailboxAuditLogSearchItem.Identity             = guid;
                mailboxAuditLogSearchItem.Name                 = mailboxAuditLogSearch.Name;
                mailboxAuditLogSearchItem.StartDate            = new ExDateTime(ExTimeZone.UtcTimeZone, mailboxAuditLogSearch.StartDateUtc.Value);
                mailboxAuditLogSearchItem.EndDate              = new ExDateTime(ExTimeZone.UtcTimeZone, mailboxAuditLogSearch.EndDateUtc.Value);
                mailboxAuditLogSearchItem.StatusMailRecipients = mailboxAuditLogSearch.StatusMailRecipients;
                mailboxAuditLogSearchItem.CreatedBy            = mailboxAuditLogSearch.CreatedBy;
                mailboxAuditLogSearchItem.CreatedByEx          = mailboxAuditLogSearch.CreatedByEx;
                mailboxAuditLogSearchItem.MailboxIds           = mailboxAuditLogSearch.Mailboxes;
                mailboxAuditLogSearchItem.LogonTypeStrings     = mailboxAuditLogSearch.LogonTypes;
                mailboxAuditLogSearchItem.Operations           = mailboxAuditLogSearch.Operations;
                mailboxAuditLogSearchItem.ShowDetails          = mailboxAuditLogSearch.ShowDetails;
                mailboxAuditLogSearchItem.ExternalAccess       = mailboxAuditLogSearch.ExternalAccess;
                mailboxAuditLogSearchItem.Save(SaveMode.ResolveConflicts);
                AuditQueuesOpticsLogData auditQueuesOpticsLogData = new AuditQueuesOpticsLogData
                {
                    QueueType      = AuditQueueType.AsyncMailboxSearch,
                    EventType      = QueueEventType.Queue,
                    CorrelationId  = guid.ToString(),
                    OrganizationId = base.MailboxSession.OrganizationId,
                    QueueLength    = base.Folder.ItemCount + 1
                };
                auditQueuesOpticsLogData.Log();
            }
        }
예제 #2
0
        internal override void Initialize(AuditLogSearchItemBase item)
        {
            MailboxAuditLogSearchItem mailboxAuditLogSearchItem = (MailboxAuditLogSearchItem)item;

            base.Initialize(item);
            this.Mailboxes   = mailboxAuditLogSearchItem.MailboxIds;
            this.LogonTypes  = mailboxAuditLogSearchItem.LogonTypeStrings;
            this.Operations  = mailboxAuditLogSearchItem.Operations;
            this.ShowDetails = mailboxAuditLogSearchItem.ShowDetails;
        }