diff --git a/Flowsharp.sln b/Flowsharp.sln index 7aa85cab3..5034d3834 100644 --- a/Flowsharp.sln +++ b/Flowsharp.sln @@ -27,6 +27,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Flowsharp.Runtime", "src\Fl EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Flowsharp.Runtime.Abstractions", "src\Flowsharp.Runtime.Abstractions\Flowsharp.Runtime.Abstractions.csproj", "{792362BF-D26D-46E9-8970-E5668941AA75}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Flowsharp.Web.Dashboard", "src\Flowsharp.Web.Dashboard\Flowsharp.Web.Dashboard.csproj", "{11836D0B-9EFF-4C84-A075-90DCB4B48EB6}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Flowsharp.Web.Components", "src\Flowsharp.Web.Components\Flowsharp.Web.Components.csproj", "{61F479BD-6DE3-4E2F-A980-80EC121E159B}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -61,6 +65,14 @@ Global {792362BF-D26D-46E9-8970-E5668941AA75}.Debug|Any CPU.Build.0 = Debug|Any CPU {792362BF-D26D-46E9-8970-E5668941AA75}.Release|Any CPU.ActiveCfg = Release|Any CPU {792362BF-D26D-46E9-8970-E5668941AA75}.Release|Any CPU.Build.0 = Release|Any CPU + {11836D0B-9EFF-4C84-A075-90DCB4B48EB6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {11836D0B-9EFF-4C84-A075-90DCB4B48EB6}.Debug|Any CPU.Build.0 = Debug|Any CPU + {11836D0B-9EFF-4C84-A075-90DCB4B48EB6}.Release|Any CPU.ActiveCfg = Release|Any CPU + {11836D0B-9EFF-4C84-A075-90DCB4B48EB6}.Release|Any CPU.Build.0 = Release|Any CPU + {61F479BD-6DE3-4E2F-A980-80EC121E159B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {61F479BD-6DE3-4E2F-A980-80EC121E159B}.Debug|Any CPU.Build.0 = Debug|Any CPU + {61F479BD-6DE3-4E2F-A980-80EC121E159B}.Release|Any CPU.ActiveCfg = Release|Any CPU + {61F479BD-6DE3-4E2F-A980-80EC121E159B}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -76,5 +88,7 @@ Global {E93A1A6B-708F-4DCC-A399-1B8EC7682F92} = {DA71CDAA-8DD3-4D5F-9FBD-8E4B37A2D925} {3C1DCAA2-D77E-4F96-9899-DA8E0E0C757F} = {DA71CDAA-8DD3-4D5F-9FBD-8E4B37A2D925} {792362BF-D26D-46E9-8970-E5668941AA75} = {DA71CDAA-8DD3-4D5F-9FBD-8E4B37A2D925} + {11836D0B-9EFF-4C84-A075-90DCB4B48EB6} = {DA71CDAA-8DD3-4D5F-9FBD-8E4B37A2D925} + {61F479BD-6DE3-4E2F-A980-80EC121E159B} = {DA71CDAA-8DD3-4D5F-9FBD-8E4B37A2D925} EndGlobalSection EndGlobal diff --git a/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml b/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml new file mode 100644 index 000000000..f154c9984 --- /dev/null +++ b/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml @@ -0,0 +1 @@ +

Hello Razor Lib Pages!

\ No newline at end of file diff --git a/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml.cs b/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml.cs new file mode 100644 index 000000000..72e0a31c5 --- /dev/null +++ b/src/Flowsharp.Web.Components/Areas/MyFeature/Pages/Page1.cshtml.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Microsoft.AspNetCore.Mvc.RazorPages; + +namespace Flowsharp.Web.Components.MyFeature.Pages +{ + public class Page1Model : PageModel + { + public void OnGet() + { + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.Components/Flowsharp.Web.Components.csproj b/src/Flowsharp.Web.Components/Flowsharp.Web.Components.csproj new file mode 100644 index 000000000..8dfc329c3 --- /dev/null +++ b/src/Flowsharp.Web.Components/Flowsharp.Web.Components.csproj @@ -0,0 +1,10 @@ + + + + netstandard2.0 + + + + + + diff --git a/src/Flowsharp.Web.Dashboard/Flowsharp.Web.Dashboard.csproj b/src/Flowsharp.Web.Dashboard/Flowsharp.Web.Dashboard.csproj new file mode 100644 index 000000000..8bfedf7d7 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Flowsharp.Web.Dashboard.csproj @@ -0,0 +1,20 @@ + + + + netcoreapp2.1 + + + + + + + + + + + + + + + + diff --git a/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml b/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml new file mode 100644 index 000000000..cb86d8354 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml @@ -0,0 +1,8 @@ +@page +@model IndexModel +@{ + ViewBag.Title = "Index"; +} + +

Index

+@* @Component.InvokeAsync("WorkflowEditor") *@ \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml.cs b/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml.cs new file mode 100644 index 000000000..4d36c2bc9 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Pages/Index.cshtml.cs @@ -0,0 +1,12 @@ +using Microsoft.AspNetCore.Mvc.RazorPages; + +namespace Flowsharp.Web.Dashboard.Pages +{ + public class IndexModel : PageModel + { + public void OnGet() + { + + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Pages/_Layout.cshtml b/src/Flowsharp.Web.Dashboard/Pages/_Layout.cshtml new file mode 100644 index 000000000..35b3f4640 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Pages/_Layout.cshtml @@ -0,0 +1,12 @@ + + + + + FlowSharp Dashboard - @ViewBag.Title + + +
+@RenderBody() +
+ + \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Pages/_ViewImports.cshtml b/src/Flowsharp.Web.Dashboard/Pages/_ViewImports.cshtml new file mode 100644 index 000000000..5e9644439 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Pages/_ViewImports.cshtml @@ -0,0 +1,3 @@ +@* @using Flowsharp.Web.Components.ViewComponents *@ +@namespace Flowsharp.Web.Dashboard.Pages +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Pages/_ViewStart.cshtml b/src/Flowsharp.Web.Dashboard/Pages/_ViewStart.cshtml new file mode 100644 index 000000000..d641c67f3 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Pages/_ViewStart.cshtml @@ -0,0 +1,3 @@ +@{ + Layout = "_Layout"; +} \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Program.cs b/src/Flowsharp.Web.Dashboard/Program.cs new file mode 100644 index 000000000..8b232cc6f --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Program.cs @@ -0,0 +1,17 @@ +using Microsoft.AspNetCore; +using Microsoft.AspNetCore.Hosting; + +namespace Flowsharp.Web.Dashboard +{ + public class Program + { + public static void Main(string[] args) + { + CreateWebHostBuilder(args).Build().Run(); + } + + public static IWebHostBuilder CreateWebHostBuilder(string[] args) => + WebHost.CreateDefaultBuilder(args) + .UseStartup(); + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Properties/launchSettings.json b/src/Flowsharp.Web.Dashboard/Properties/launchSettings.json new file mode 100644 index 000000000..16b39cfa7 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Properties/launchSettings.json @@ -0,0 +1,27 @@ +{ + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:41579", + "sslPort": 44397 + } + }, + "profiles": { + "IIS Express": { + "commandName": "IISExpress", + "launchBrowser": true, + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "Flowsharp.Dashboard.Web": { + "commandName": "Project", + "launchBrowser": true, + "applicationUrl": "https://localhost:5001;http://localhost:5000", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.Dashboard/Startup.cs b/src/Flowsharp.Web.Dashboard/Startup.cs new file mode 100644 index 000000000..d929fba65 --- /dev/null +++ b/src/Flowsharp.Web.Dashboard/Startup.cs @@ -0,0 +1,25 @@ +using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Hosting; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.DependencyInjection; + +namespace Flowsharp.Web.Dashboard +{ + public class Startup + { + public void ConfigureServices(IServiceCollection services) + { + services.AddMvc(); + } + + public void Configure(IApplicationBuilder app, IHostingEnvironment env) + { + if (env.IsDevelopment()) + { + app.UseDeveloperExceptionPage(); + } + + app.UseMvc(); + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.UI2/Flowsharp.Web.UI.csproj b/src/Flowsharp.Web.UI2/Flowsharp.Web.UI.csproj new file mode 100644 index 000000000..3c40358fe --- /dev/null +++ b/src/Flowsharp.Web.UI2/Flowsharp.Web.UI.csproj @@ -0,0 +1,16 @@ + + + + netcoreapp2.1 + + + + + + + + + + + + diff --git a/src/Flowsharp.Web.UI2/Program.cs b/src/Flowsharp.Web.UI2/Program.cs new file mode 100644 index 000000000..900496c6c --- /dev/null +++ b/src/Flowsharp.Web.UI2/Program.cs @@ -0,0 +1,17 @@ +using Microsoft.AspNetCore; +using Microsoft.AspNetCore.Hosting; + +namespace Flowsharp.Web.UI +{ + public class Program + { + public static void Main(string[] args) + { + CreateWebHostBuilder(args).Build().Run(); + } + + public static IWebHostBuilder CreateWebHostBuilder(string[] args) => + WebHost.CreateDefaultBuilder(args) + .UseStartup(); + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.UI2/Properties/launchSettings.json b/src/Flowsharp.Web.UI2/Properties/launchSettings.json new file mode 100644 index 000000000..8702a7696 --- /dev/null +++ b/src/Flowsharp.Web.UI2/Properties/launchSettings.json @@ -0,0 +1,27 @@ +{ + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:62188", + "sslPort": 44393 + } + }, + "profiles": { + "IIS Express": { + "commandName": "IISExpress", + "launchBrowser": true, + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "Flowsharp.UI.Web": { + "commandName": "Project", + "launchBrowser": true, + "applicationUrl": "https://localhost:5001;http://localhost:5000", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.UI2/Shared/Components/WorkflowEditor/Default.cshtml b/src/Flowsharp.Web.UI2/Shared/Components/WorkflowEditor/Default.cshtml new file mode 100644 index 000000000..62fbdb2d5 --- /dev/null +++ b/src/Flowsharp.Web.UI2/Shared/Components/WorkflowEditor/Default.cshtml @@ -0,0 +1,5 @@ +@model dynamic + +
+ Workflow editor +
\ No newline at end of file diff --git a/src/Flowsharp.Web.UI2/Startup.cs b/src/Flowsharp.Web.UI2/Startup.cs new file mode 100644 index 000000000..6cbde9b9c --- /dev/null +++ b/src/Flowsharp.Web.UI2/Startup.cs @@ -0,0 +1,27 @@ +using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Hosting; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.DependencyInjection; + +namespace Flowsharp.Web.UI +{ + public class Startup + { + // This method gets called by the runtime. Use this method to add services to the container. + // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940 + public void ConfigureServices(IServiceCollection services) + { + } + + // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. + public void Configure(IApplicationBuilder app, IHostingEnvironment env) + { + if (env.IsDevelopment()) + { + app.UseDeveloperExceptionPage(); + } + + app.Run(async (context) => { await context.Response.WriteAsync("Hello World!"); }); + } + } +} \ No newline at end of file diff --git a/src/Flowsharp.Web.UI2/ViewComponents/WorkflowEditorViewComponent.cs b/src/Flowsharp.Web.UI2/ViewComponents/WorkflowEditorViewComponent.cs new file mode 100644 index 000000000..0a7bf7868 --- /dev/null +++ b/src/Flowsharp.Web.UI2/ViewComponents/WorkflowEditorViewComponent.cs @@ -0,0 +1,14 @@ +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; + +namespace Flowsharp.Web.UI.ViewComponents +{ + public class WorkflowEditorViewComponent : ViewComponent + { + public async Task InvokeAsync(CancellationToken cancellationToken) + { + return View(); + } + } +} \ No newline at end of file