コード例 #1
0
        protected void InitComponent()
        {
            GrouperService = new ValueGrouper();
            SmartUrl       = new SmartUrl();

            ApiViewer = new ApiViewer(GrouperService, SmartUrl);
            SqlViewer = new SqlViewer(GrouperService, SmartUrl);
            if (Configs.IsUsingSolr)
            {
                SolrViewer = new SolrViewer();
            }

            InitDropDowns();
        }
コード例 #2
0
        protected void LoadItem(params LensInput[] input)
        {
            // Init values comparison
            GrouperService.Reset();

            // Populate API/Cached results
            ResultApiMaster.Text = ApiViewer.GetHtml(input?[0]);
            ResultApiWeb.Text    = ApiViewer.GetHtml(input?[1]);

            // Populate SQL results
            ResultSqlMaster.Text = SqlViewer.GetHtml(input?[0]);
            ResultSqlWeb.Text    = SqlViewer.GetHtml(input?[1]);

            // Populate Solr results
            if (Configs.IsUsingSolr)
            {
                litIndexesLeft.Text  = SolrViewer.GetHtml(input?[0]);
                litIndexesRight.Text = SolrViewer.GetHtml(input?[1]);
            }
            // Set Share
            litShare.Text = $"<a href=\"?{SmartUrl.ToQueryString(input)}\" class=\"btn btn-secondary\">Share Link</a>";
        }