diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL.sln b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL.sln
new file mode 100644
index 0000000..d6176bc
--- /dev/null
+++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL.sln
@@ -0,0 +1,31 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.8.34525.116
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Grid_PostgreSQL", "Grid_PostgreSQL\Grid_PostgreSQL\Grid_PostgreSQL.csproj", "{17D02420-654A-46E1-9B1B-FC94FEE6187C}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Grid_PostgreSQL.Client", "Grid_PostgreSQL\Grid_PostgreSQL.Client\Grid_PostgreSQL.Client.csproj", "{6E102EB2-51BB-4D15-822E-AE2F3173AB3D}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {17D02420-654A-46E1-9B1B-FC94FEE6187C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {17D02420-654A-46E1-9B1B-FC94FEE6187C}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {17D02420-654A-46E1-9B1B-FC94FEE6187C}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {17D02420-654A-46E1-9B1B-FC94FEE6187C}.Release|Any CPU.Build.0 = Release|Any CPU
+ {6E102EB2-51BB-4D15-822E-AE2F3173AB3D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {6E102EB2-51BB-4D15-822E-AE2F3173AB3D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {6E102EB2-51BB-4D15-822E-AE2F3173AB3D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {6E102EB2-51BB-4D15-822E-AE2F3173AB3D}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {5D4CDB6C-305D-4C9A-9EA1-8540ACE9932A}
+ EndGlobalSection
+EndGlobal
diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Grid_PostgreSQL.Client.csproj b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Grid_PostgreSQL.Client.csproj
new file mode 100644
index 0000000..8fd8f57
--- /dev/null
+++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Grid_PostgreSQL.Client.csproj
@@ -0,0 +1,15 @@
+
Current count: @currentCount
+ + + +@code { + private int currentCount = 0; + + private void IncrementCount() + { + currentCount++; + } +} diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Program.cs b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Program.cs new file mode 100644 index 0000000..519269f --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/Program.cs @@ -0,0 +1,5 @@ +using Microsoft.AspNetCore.Components.WebAssembly.Hosting; + +var builder = WebAssemblyHostBuilder.CreateDefault(args); + +await builder.Build().RunAsync(); diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/_Imports.razor b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/_Imports.razor new file mode 100644 index 0000000..0aef71a --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/_Imports.razor @@ -0,0 +1,9 @@ +@using System.Net.Http +@using System.Net.Http.Json +@using Microsoft.AspNetCore.Components.Forms +@using Microsoft.AspNetCore.Components.Routing +@using Microsoft.AspNetCore.Components.Web +@using static Microsoft.AspNetCore.Components.Web.RenderMode +@using Microsoft.AspNetCore.Components.Web.Virtualization +@using Microsoft.JSInterop +@using Grid_PostgreSQL.Client diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.Development.json b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.Development.json new file mode 100644 index 0000000..0c208ae --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.Development.json @@ -0,0 +1,8 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + } +} diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.json b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.json new file mode 100644 index 0000000..0c208ae --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL.Client/wwwroot/appsettings.json @@ -0,0 +1,8 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + } +} diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/App.razor b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/App.razor new file mode 100644 index 0000000..e62b00f --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/App.razor @@ -0,0 +1,22 @@ + + + + + + +
+ Request ID: @RequestId
+
+ Swapping to Development environment will display more detailed information about the error that occurred. +
++ The Development environment shouldn't be enabled for deployed applications. + It can result in displaying sensitive information from exceptions to end users. + For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development + and restarting the app. +
+ +@code{ + [CascadingParameter] + private HttpContext? HttpContext { get; set; } + + private string? RequestId { get; set; } + private bool ShowRequestId => !string.IsNullOrEmpty(RequestId); + + protected override void OnInitialized() => + RequestId = Activity.Current?.Id ?? HttpContext?.TraceIdentifier; +} diff --git a/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/Pages/Home.razor b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/Pages/Home.razor new file mode 100644 index 0000000..aa41695 --- /dev/null +++ b/Binding PostgreSQL database using CustomAdaptor/Grid_PostgreSQL/Grid_PostgreSQL/Grid_PostgreSQL/Components/Pages/Home.razor @@ -0,0 +1,214 @@ +@page "/" + + +@rendermode InteractiveServer + +@using Syncfusion.Blazor.Grids +@using Syncfusion.Blazor.Data +@using Syncfusion.Blazor +@using Grid_PostgreSQL.Data; +@using System.Collections + +Sum: @aggregate.Sum
+Average: @aggregate.Average
+