Skip to content

Commit

Permalink
Merge pull request #147 from RevealBi/refactor/update-sandbox
Browse files Browse the repository at this point in the history
Pre-add sandbox examples
  • Loading branch information
hainv-ohio authored Dec 12, 2024
2 parents fa45ce9 + 946507c commit ea15491
Show file tree
Hide file tree
Showing 18 changed files with 338 additions and 3 deletions.
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/AmazonRedshiftDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class AmazonRedshiftDashboard : IDashboardCreator
{
public string Name => "Amazon Redshift Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/AmazonS3Dashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class AmazonS3Dashboard : IDashboardCreator
{
public string Name => "Amazon S3 Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/GoogleAnalytic4Dashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class GoogleAnalytic4Dashboard : IDashboardCreator
{
public string Name => "Google Analytic4 Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/GoogleBigQueryDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class GoogleBigQueryDashboard : IDashboardCreator
{
public string Name => "Google Big Query Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/GoogleDriveDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class GoogleDriveDashboard : IDashboardCreator
{
public string Name => "Google Drive Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/GoogleSheetDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class GoogleSheetDashboard : IDashboardCreator
{
public string Name => "Google Sheet Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/HttpAnalysisDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class HttpAnalysisDashboard : IDashboardCreator
{
public string Name => "Http Analysis Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/MSAnalysisServiceDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class MSAnalysisServiceDashboard : IDashboardCreator
{
public string Name => "MS Analysis Service Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/MSAzureAnalysisServiceDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class MSAzureAnalysisServiceDashboard : IDashboardCreator
{
public string Name => "MS Azure Analysis Service Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
20 changes: 20 additions & 0 deletions e2e/Sandbox/DashboardCreators/MSAzureSqlDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
using Reveal.Sdk.Dom;
using Sandbox.DashboardFactories;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class MSAzureSqlDashboard : IDashboardCreator
{
public string Name => "MS Azure Sql Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/MongoDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class MongoDashboard : IDashboardCreator
{
public string Name => "Mongo Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/MySqlDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class MySqlDashboard : IDashboardCreator
{
public string Name => "MySql data source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/ODataDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class ODataDashboard : IDashboardCreator
{
public string Name => "OData Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/OracleDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class OracleDashboard : IDashboardCreator
{
public string Name => "Oracle Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
2 changes: 1 addition & 1 deletion e2e/Sandbox/DashboardCreators/SnowFlakeDashboard.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ public RdashDocument CreateDashboard()
return document;
}
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/SynapseAnalyticsDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class SynapseAnalyticsDashboard : IDashboardCreator
{
public string Name => "MS Synapse Analytics DataSource";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
19 changes: 19 additions & 0 deletions e2e/Sandbox/DashboardCreators/WebServiceDataSourceDashboard.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using Reveal.Sdk.Dom;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Sandbox.DashboardFactories
{
internal class WebServiceDataSourceDashboard : IDashboardCreator
{
public string Name => "Web Service Data Source";

public RdashDocument CreateDashboard()
{
throw new NotImplementedException();
}
}
}
34 changes: 32 additions & 2 deletions e2e/Sandbox/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,18 +43,33 @@ public partial class MainWindow : Window
List<IDashboardCreator> _dashboardCreators = new List<IDashboardCreator>
{
new AmazonAthenaDashboard(),
new AmazonS3Dashboard(),
new AmazonRedshiftDashboard(),
new CampaignsDashboard(),
new CustomDashboard(),
new DashboardLinkingDashboard(),
new GoogleAnalytic4Dashboard(),
new GoogleBigQueryDashboard(),
new GoogleDriveDashboard(),
new GoogleSheetDashboard(),
new HealthcareDashboard(),
new HttpAnalysisDashboard(),
new ManufacturingDashboard(),
new MarketingDashboard(),
new MongoDashboard(),
new MSAnalysisServiceDashboard(),
new MSAzureAnalysisServiceDashboard(),
new MSAzureSqlDashboard(),
new MySqlDashboard(),
new MSAzureSqlServerDSDashboard(),
new ODataDashboard(),
new OracleDashboard(),
new PostgresqlDashboard(),
new RestDataSourceDashboard(),
new SalesDashboard(),
new SnowflakeDashboard(),
new SqlServerDataSourceDashboards(),
new WebServiceDataSourceDashboard(),
};

public MainWindow()
Expand All @@ -63,8 +78,22 @@ public MainWindow()

RevealSdkSettings.DataSourceProvider = new DataSourceProvider();
RevealSdkSettings.AuthenticationProvider = new AuthenticationProvider();
RevealSdkSettings.DataSources.RegisterMicrosoftSqlServer().RegisterMicrosoftAnalysisServices().RegisterPostgreSQL().RegisterAmazonAthena();
RevealSdkSettings.DataSources.RegisterSnowflake();
RevealSdkSettings.DataSources
.RegisterMicrosoftSqlServer()
.RegisterMicrosoftAnalysisServices()
.RegisterPostgreSQL()
.RegisterAmazonAthena()
.RegisterMicrosoftSynapseAnalytics()
.RegisterSnowflake()
.RegisterMySql()
.RegisterMongoDB()
.RegisterGoogleDrive()
.RegisterGoogleBigQuery()
.RegisterGoogleAnalytics4()
.RegisterAmazonRedshift()
.RegisterAmazonS3()
.RegisterGoogleDrive()
.RegisterOracle();

LoadDashboards();

Expand Down Expand Up @@ -223,6 +252,7 @@ private async void CreateDashboardWithTypeBtn_Click(object sender, RoutedEventAr
if (creator != null)
{
RdashDocument document = creator.CreateDashboard();

var json = document.ToJsonString();
_revealView.Dashboard = await RVDashboard.LoadFromJsonAsync(json);

Expand Down

0 comments on commit ea15491

Please sign in to comment.