private List <Folder> GetSubFoldersByBasicFolderDefinition(ISiteSetting siteSetting, Folder folder, BasicFolderDefinition basicFolderDefinition, bool returnAll)
        {
            if (basicFolderDefinition.Folders.Count > 0)
            {
                List <Folder> subFolders = ServiceManagerFactory.GetServiceManager(siteSetting.SiteSettingType).GetFolders(siteSetting, folder);
                foreach (Folder subFolder in subFolders)
                {
                    BasicFolderDefinition subBasicFolderDefinition = basicFolderDefinition.Folders.Single(t => t.FolderUrl == subFolder.GetUrl());
                    if (basicFolderDefinition != null)
                    {
                        subFolder.Selected = true;
                    }

                    if (returnAll == true || basicFolderDefinition != null)
                    {
                        folder.Folders.Add(subFolder);
                    }

                    subFolder.Folders = GetSubFoldersByBasicFolderDefinition(siteSetting, subFolder, subBasicFolderDefinition, returnAll);
                }

                return(subFolders);
            }

            return(new List <Folder>());
        }
        public Folder GetFolderByBasicFolderDefinition(ISiteSetting siteSetting, BasicFolderDefinition basicFolderDefinition, bool returnAll)
        {
            Folder folder = ServiceManagerFactory.GetServiceManager(siteSetting.SiteSettingType).GetFolder(siteSetting, basicFolderDefinition);

            folder.Selected = true;

            folder.Folders = GetSubFoldersByBasicFolderDefinition(siteSetting, folder, basicFolderDefinition, returnAll);

            return(folder);
        }
        public Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition)
        {
            ISharePointService spService = new SharePointService();

            if (typeof(SPList).FullName.Equals(folderDefinition.FolderType, StringComparison.OrdinalIgnoreCase) == true)
            {
                return(spService.GetList(siteSetting, folderDefinition.FolderUrl));
            }
            else if (typeof(SPWeb).FullName.Equals(folderDefinition.FolderType, StringComparison.OrdinalIgnoreCase) == true)
            {
                return(spService.GetWeb(siteSetting, folderDefinition.FolderUrl));
            }
            else
            {
                return(spService.GetFolder(siteSetting, folderDefinition.FolderUrl));
            }
        }
        void callback(object args, DateTime dateTime)
        {
            object[]              arguments = args as object[];
            StackPanel            searchFiltersListPanel = arguments[0] as StackPanel;
            SiteSetting           siteSetting            = arguments[1] as SiteSetting;
            BasicFolderDefinition folder = arguments[2] as BasicFolderDefinition;
            string contentTypeID         = arguments[3] as string;
            Dictionary <string, SearchFilters> searchFilters = arguments[4] as Dictionary <string, SearchFilters>;

            IServiceManager serviceManager = ServiceManagerFactory.GetServiceManager(siteSetting.SiteSettingType);
            Folder          targetFolder   = serviceManager.GetFolder(siteSetting, folder);

            this.ContentType = serviceManager.GetContentType(siteSetting, targetFolder, contentTypeID, false);

            searchFiltersListPanel.Dispatcher.Invoke(DispatcherPriority.Input, new ThreadStart(() =>
            {
                SearchFilter filter = new Entities.Search.SearchFilter(string.Empty, FieldTypes.Text, CamlFilterTypes.Contains, string.Empty);
                searchFilterControl1.Initialize(targetFolder.GetWebUrl(), this.ContentType, filter, true);
                this.RefreshSearchFiltersListPanel(searchFiltersListPanel, searchFilters, this.ContentType);

                this.HideLoadingStatus("Ready");
            }));
        }
        public Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition)
        {
            DirectoryInfo di = new DirectoryInfo(folderDefinition.FolderUrl);

            return(new FSFolder(siteSetting.ID, folderDefinition.FolderUrl, folderDefinition.Title, folderDefinition.FolderUrl));
        }
 public OutlookConfigurations()
 {
     DefaultAttachmentSaveFolder = new BasicFolderDefinition();
 }
        public override Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition)
        {
            IServiceManager serviceManager = ServiceManagerFactory.GetServiceManager(siteSetting.SiteSettingType);

            return(serviceManager.GetFolder(siteSetting, folderDefinition));
        }
 public void Initialize(SiteSetting siteSetting, BasicFolderDefinition targetFolder, string contentTypeID)
 {
     this.SiteSetting   = siteSetting;
     this.ContentTypeID = contentTypeID;
     this.TargetFolder  = targetFolder;
 }
 public abstract Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition);
Example #10
0
        public Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition)
        {
            ICRMService spService = new CRMService();

            return(null);
        }
Example #11
0
 public Folder GetFolder(ISiteSetting siteSetting, BasicFolderDefinition folderDefinition)
 {
     throw new Exception("Not implemented yet");
 }
Example #12
0
 public Folder GetFolderByBasicFolderDefinition(ISiteSetting siteSetting, BasicFolderDefinition basicFolderDefinition, bool returnAll)
 {
     throw new Exception("Not implemented yet");
 }
 private List <Folder> GetSubFoldersByBasicFolderDefinition(ISiteSetting siteSetting, Folder folder, BasicFolderDefinition basicFolderDefinition, bool returnAll)
 {
     throw new Exception("Not implemented yet");
 }