Example #1
0
        public secCrawlerData.tblSEC_FormsDataTable GetFormsByFullTextSearchAndFormType(string searchCriteria, string formType, LinkResponseType makeURLClickable, string customURL)
        {
            var table = _adapter.GetDataByFullTextSearchAndFormType(searchCriteria, formType);

            if (makeURLClickable == LinkResponseType.ClickableWithAbsolutePath)
            {
                var basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = "<A href=\"" + basePath + rowF.FormPartialURL + "\">" + rowF.FormPartialURL + "</A>";
                }
            }
            if (makeURLClickable == LinkResponseType.ClickableWithModifiedLink)
            {
                var basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = "<A href=\"" + customURL + rowF.FormID.ToString() + "\">" + rowF.FormPartialURL + "</A>";
                }
            }
            if (makeURLClickable == LinkResponseType.NotClickableWithModifiedPath)
            {
                string basePath;
                if (string.IsNullOrEmpty(customURL))
                {
                    basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                }
                else
                {
                    basePath = customURL;
                }
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = basePath + rowF.FormPartialURL;
                }
            }

            return(table);
        }
Example #2
0
 public DtstSECCrawlerViews.spCOI_fullTextSearchByFormTypeWithSnippetDataTable GetFormsByFullTextSearchAndFormTypeWithSnippet(string searchCriteria, string formType, LinkResponseType makeURLClickable, string customURL)
 {
     return(GetFormsByFullTextSearchAndFormTypeWithSnippet(searchCriteria, formType, makeURLClickable, customURL, "%"));
 }
Example #3
0
        public DtstSECCrawlerViews.spCOI_fullTextSearchByFormTypeWithSnippetDataTable GetFormsByFullTextSearchAndFormTypeWithSnippet(string searchCriteria, string formType, LinkResponseType makeURLClickable, string customURL, string coName)
        {
            var adapter1 = new DtstSECCrawlerViewsTableAdapters.spCOI_fullTextSearchByFormTypeWithSnippetTableAdapter();
            var table    = adapter1.GetData(searchCriteria, formType, coName);

            if (makeURLClickable == LinkResponseType.ClickableWithAbsolutePath)
            {
                var basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = "<A target=_blank href=\"" + basePath + rowF.FormPartialURL + "\">" + rowF.FormPartialURL + "</A>";
                }
            }
            if (makeURLClickable == LinkResponseType.ClickableWithModifiedLink)
            {
                var basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = "<A target=_blank href=\"" + customURL + rowF.FormID.ToString() + "\">" + rowF.FormPartialURL + "</A>";
                }
            }
            if (makeURLClickable == LinkResponseType.NotClickableWithModifiedPath)
            {
                string basePath;
                if (string.IsNullOrEmpty(customURL))
                {
                    basePath = (string)ConfigReader.GetValue("LocalDataStoreWebShare", string.Empty.GetType());
                }
                else
                {
                    basePath = customURL;
                }
                foreach (var rowF in table)
                {
                    rowF.FormPartialURL = basePath + rowF.FormPartialURL;
                }
            }

            return(table);
        }