Exemple #1
0
        private static string GenerateGroupContent(CultureInfo cultureInfo, ModernGroupObjectType groupType = ModernGroupObjectType.None, string inboxUrl = null, string calendarUrl = null, string sharePointUrl = null)
        {
            bool   flag = string.IsNullOrEmpty(inboxUrl);
            string arg  = string.Format("<div style=\"margin:0 20px 5px 20px\">{0}<img onerror='this.style.display=\"none\"' border=\"0\"src=\"{1}\"width=\"64\"height=\"64\">{2}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:14pt\">{3}</div><div style=\"margin:5px 20px;color:#666666;font-size:10pt\">{4}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:10pt\">{5}</div>", new object[]
            {
                flag?string.Empty: string.Format("<a href=\"{0}\">", inboxUrl),
                "cid:" + WelcomeMessageBodyBuilder.ConversationIcon.ImageId,
                flag ? string.Empty : "</a>",
                ClientStrings.GroupMailboxAddedMemberMessageConversation1.ToString(cultureInfo),
                ClientStrings.GroupMailboxAddedMemberMessageConversation2.ToString(cultureInfo),
                flag ? string.Empty : string.Format("<a href=\"{0}\">{1}</a>", inboxUrl, ClientStrings.GroupMailboxAddedMemberMessageConversation3.ToString(cultureInfo))
            });
            bool   flag2 = string.IsNullOrEmpty(sharePointUrl);
            string arg2  = string.Format("<div style=\"margin:0 20px 5px 20px\">{0}<img onerror='this.style.display=\"none\"' border=\"0\"src=\"{1}\"width=\"64\"height=\"64\">{2}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:14pt\">{3}</div><div style=\"margin:5px 20px;color:#666666;font-size:10pt\">{4}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:10pt\">{5}</div>", new object[]
            {
                flag2?string.Empty: string.Format("<a href=\"{0}\">", sharePointUrl),
                "cid:" + WelcomeMessageBodyBuilder.DocumentIcon.ImageId,
                flag2 ? string.Empty : "</a>",
                ClientStrings.GroupMailboxAddedMemberMessageDocument1.ToString(cultureInfo),
                ClientStrings.GroupMailboxAddedMemberMessageDocument2.ToString(cultureInfo),
                flag2 ? string.Empty : string.Format("<a href=\"{0}\">{1}</a>", sharePointUrl, ClientStrings.GroupMailboxAddedMemberMessageDocument3.ToString(cultureInfo))
            });
            bool   flag3 = string.IsNullOrEmpty(calendarUrl);
            string arg3  = string.Format("<div style=\"margin:0 20px 5px 20px\">{0}<img onerror='this.style.display=\"none\"' border=\"0\"src=\"{1}\"width=\"64\"height=\"64\">{2}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:14pt\">{3}</div><div style=\"margin:5px 20px;color:#666666;font-size:10pt\">{4}</div><div style=\"margin:5px 20px;color:#0072C6;font-size:10pt\">{5}</div>", new object[]
            {
                flag3?string.Empty: string.Format("<a href=\"{0}\">", calendarUrl),
                "cid:" + WelcomeMessageBodyBuilder.CalendarIcon.ImageId,
                flag3 ? string.Empty : "</a>",
                ClientStrings.GroupMailboxAddedMemberMessageCalendar1.ToString(cultureInfo),
                ClientStrings.GroupMailboxAddedMemberMessageCalendar2.ToString(cultureInfo),
                flag3 ? string.Empty : string.Format("<a href=\"{0}\">{1}</a>", calendarUrl, ClientStrings.GroupMailboxAddedMemberMessageCalendar3.ToString(cultureInfo))
            });

            return(string.Format("<td valign=\"top\"width=\"213\">{0}</td><td valign=\"top\"width=\"213\">{1}</td><td valign=\"top\"width=\"213\">{2}</td>", arg, arg2, arg3));
        }
Exemple #2
0
        // Token: 0x060055F4 RID: 22004 RVA: 0x00135E34 File Offset: 0x00134034
        internal static MultiValuedProperty <SecurityIdentifier> PublicToGroupSidsGetter(IPropertyBag propertyBag)
        {
            MultiValuedProperty <ADObjectId>         multiValuedProperty   = (MultiValuedProperty <ADObjectId>)propertyBag[GroupMailboxSchema.DelegateListLink];
            ModernGroupObjectType                    modernGroupObjectType = (ModernGroupObjectType)propertyBag[GroupMailboxSchema.ModernGroupType];
            MultiValuedProperty <SecurityIdentifier> multiValuedProperty2  = new MultiValuedProperty <SecurityIdentifier>();

            if (multiValuedProperty != null && multiValuedProperty.Count > 0)
            {
                using (MultiValuedProperty <ADObjectId> .Enumerator enumerator = multiValuedProperty.GetEnumerator())
                {
                    while (enumerator.MoveNext())
                    {
                        ADObjectId         instance           = enumerator.Current;
                        SecurityIdentifier securityIdentifier = ADObjectId.GetSecurityIdentifier(instance);
                        if (securityIdentifier != null)
                        {
                            multiValuedProperty2.Add(securityIdentifier);
                        }
                    }
                    return(multiValuedProperty2);
                }
            }
            if (modernGroupObjectType == ModernGroupObjectType.Public)
            {
                SecurityIdentifier item = new SecurityIdentifier(WellKnownSidType.WorldSid, null);
                multiValuedProperty2.Add(item);
            }
            return(multiValuedProperty2);
        }
Exemple #3
0
        private static string GetGroupTypeMessage(ModernGroupObjectType groupType, CultureInfo cultureInfo)
        {
            switch (groupType)
            {
            case ModernGroupObjectType.Private:
                return(ClientStrings.GroupMailboxWelcomeEmailPrivateTypeText.ToString(cultureInfo));

            case ModernGroupObjectType.Public:
                return(ClientStrings.GroupMailboxWelcomeEmailPublicTypeText.ToString(cultureInfo));
            }
            return(string.Empty);
        }
Exemple #4
0
        private string GetGroupTypeMessage(ModernGroupObjectType groupType)
        {
            switch (groupType)
            {
            case ModernGroupObjectType.Private:
                return(this.GetLocalizedString(ClientStrings.GroupSubscriptionPagePrivateGroupInfo));

            case ModernGroupObjectType.Public:
                return(this.GetLocalizedString(ClientStrings.GroupSubscriptionPagePublicGroupInfo));
            }
            return(string.Empty);
        }
Exemple #5
0
        internal static ModernGroupTypeType Convert(ModernGroupObjectType type)
        {
            switch (type)
            {
            case ModernGroupObjectType.Private:
                return(ModernGroupTypeType.Private);

            case ModernGroupObjectType.Secret:
                return(ModernGroupTypeType.Secret);

            case ModernGroupObjectType.Public:
                return(ModernGroupTypeType.Public);
            }
            return(ModernGroupTypeType.None);
        }
 // Token: 0x06001AF7 RID: 6903 RVA: 0x000663EC File Offset: 0x000645EC
 public Implementation(AttachmentDataProvider provider, IXSOFactory factory, IStoreSession attachmentSession, ModernGroupObjectType attachmentSessionModernGroupType, IItem rootItem, IAttachment attachment, string attachmentId, IMailboxSession draftAttachmentSession, StoreObjectId draftObjectId, bool isEdit, string userDisplayName, Func <IStoreSession, StoreId, AttachmentId, string> idConverter)
 {
     this.provider = provider;
     this.factory  = factory;
     this.originalAttachmentSession      = attachmentSession;
     this.originalSessionModernGroupType = attachmentSessionModernGroupType;
     this.originalAttachmentRootItem     = rootItem;
     this.originalAttachment             = attachment;
     this.originalAttachmentId           = attachmentId;
     this.draftAttachmentSession         = draftAttachmentSession;
     this.draftObjectId   = draftObjectId;
     this.isEdit          = isEdit;
     this.userDisplayName = userDisplayName;
     this.idConverter     = idConverter;
 }