private void InitView() { AnalyticsService srv = new AnalyticsService(); var ctx = srv.CreateAuthorizationContext(); IAnalyticsSystemInfo systemInfo = srv.GetAnalyticsSystemInfo(); string dashboardName = this.Page.Request.Params["Dashboard"]; if (srv.HasDashboardAccess(dashboardName)) { IAnalyticsDashboard dashboard = srv.GetAnalyticsDashboard(dashboardName); string dashboardPath = dashboard.Path; DashboardTitle = dashboard.DisplayName; string url = string.Format(@"{0}/SLXDashboard.aspx?file={1}&AuthId={2}", systemInfo.WebPlayerUrl, HttpUtility.UrlEncode(dashboardPath), ctx.AuthId); //string url = string.Format(@"{0}/ViewAnalysis.aspx?file={1}", systemInfo.WebPlayerUrl, HttpUtility.UrlEncode(dashboardPath)); IframeDashboard.Attributes.Add("src", url); } else { divNoAccess.Style.Value = "display:Allow;"; divFrame.Style.Value = "display:none;"; } var workSpace = _parentWorkItem.Workspaces["MainContent"] as MainContentWorkspace; if (workSpace != null) { workSpace.HideTitleBar = true; } HtmlContainerControl localTitle = this.Page.Master.FindControl("localTitle") as HtmlContainerControl; if (localTitle != null) { localTitle.Style.Value = "display:none;"; } }
private void LoadView() { IAnalayticsService srv = new AnalyticsService(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); txtSystemUrl.Text = AnalyticsSystemInfo.URL; txtWebPlayerUrl.Text = AnalyticsSystemInfo.WebPlayerUrl; LoadDashboards(); }
private void LoadDashboards() { IList<IAnalyticsDashboard> dashboards = new List<IAnalyticsDashboard>(); AnalyticsService srv = new AnalyticsService(); dashboards = srv.GetAnalyticsDashboards(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); grdDashboards.DataSource = dashboards; grdDashboards.DataBind(); }
protected void TestDashboard(IAnalyticsDashboard dashbaord) { AnalyticsService srv = new AnalyticsService(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); var ctx = srv.CreateAuthorizationContext(); string dashboardPath = dashbaord.Path; string url = string.Format(@"{0}/SLXDashboard.aspx?file={1}&AuthId={2}", AnalyticsSystemInfo.WebPlayerUrl, HttpUtility.UrlEncode(dashboardPath), ctx.AuthId); TestUrl(url); }
protected void btnSave_ClickAction(object sender, EventArgs e) { IAnalayticsService srv = new AnalyticsService(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); AnalyticsSystemInfo.URL = txtSystemUrl.Text; AnalyticsSystemInfo.WebPlayerUrl = txtWebPlayerUrl.Text; AnalyticsSystemInfo.Save(); }
protected void btnOpenWebPalyer_ClickAction(object sender, EventArgs e) { AnalyticsService srv = new AnalyticsService(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); var ctx = srv.CreateAuthorizationContext(); string url = string.Format("{0}?AuthId={1}", txtWebPlayerUrl.Text, ctx.AuthId); TestUrl(url); }
protected void btnOpenSystem_ClickAction(object sender, EventArgs e) { AnalyticsService srv = new AnalyticsService(); AnalyticsSystemInfo = srv.GetAnalyticsSystemInfo(); string url = string.Format("{0}", txtSystemUrl.Text); TestUrl(url); }