From 2c87953f15bf3159906c094be7e398d296556f8c Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Sat, 28 Oct 2017 16:01:27 -0500 Subject: [PATCH] FilterLists.Web initial commit --- FilterLists.sln | 6 +++ .../Controllers/HomeController.cs | 12 ++++++ src/FilterLists.Web/FilterLists.Web.csproj | 22 +++++++++++ src/FilterLists.Web/Program.cs | 20 ++++++++++ src/FilterLists.Web/Startup.cs | 37 +++++++++++++++++++ src/FilterLists.Web/Views/Home/Index.cshtml | 3 ++ 6 files changed, 100 insertions(+) create mode 100644 src/FilterLists.Web/Controllers/HomeController.cs create mode 100644 src/FilterLists.Web/FilterLists.Web.csproj create mode 100644 src/FilterLists.Web/Program.cs create mode 100644 src/FilterLists.Web/Startup.cs create mode 100644 src/FilterLists.Web/Views/Home/Index.cshtml diff --git a/FilterLists.sln b/FilterLists.sln index bb6d278b6..ab8d40dfd 100644 --- a/FilterLists.sln +++ b/FilterLists.sln @@ -8,6 +8,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FilterLists.Data", "src\Fil EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "FilterLists.Services", "src\FilterLists.Services\FilterLists.Services.csproj", "{9F296ECF-97C9-47E6-A794-5AD900ECFE6C}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FilterLists.Web", "src\FilterLists.Web\FilterLists.Web.csproj", "{FD01C9D2-EBAB-4A71-B6E9-4951179CA4C4}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -26,6 +28,10 @@ Global {9F296ECF-97C9-47E6-A794-5AD900ECFE6C}.Debug|Any CPU.Build.0 = Debug|Any CPU {9F296ECF-97C9-47E6-A794-5AD900ECFE6C}.Release|Any CPU.ActiveCfg = Release|Any CPU {9F296ECF-97C9-47E6-A794-5AD900ECFE6C}.Release|Any CPU.Build.0 = Release|Any CPU + {FD01C9D2-EBAB-4A71-B6E9-4951179CA4C4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {FD01C9D2-EBAB-4A71-B6E9-4951179CA4C4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {FD01C9D2-EBAB-4A71-B6E9-4951179CA4C4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {FD01C9D2-EBAB-4A71-B6E9-4951179CA4C4}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/src/FilterLists.Web/Controllers/HomeController.cs b/src/FilterLists.Web/Controllers/HomeController.cs new file mode 100644 index 000000000..0311c451d --- /dev/null +++ b/src/FilterLists.Web/Controllers/HomeController.cs @@ -0,0 +1,12 @@ +using Microsoft.AspNetCore.Mvc; + +namespace FilterLists.Web.Controllers +{ + public class HomeController : Controller + { + public IActionResult Index() + { + return View(); + } + } +} \ No newline at end of file diff --git a/src/FilterLists.Web/FilterLists.Web.csproj b/src/FilterLists.Web/FilterLists.Web.csproj new file mode 100644 index 000000000..e2b4916ad --- /dev/null +++ b/src/FilterLists.Web/FilterLists.Web.csproj @@ -0,0 +1,22 @@ + + + + netcoreapp2.0 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/FilterLists.Web/Program.cs b/src/FilterLists.Web/Program.cs new file mode 100644 index 000000000..bc18c5102 --- /dev/null +++ b/src/FilterLists.Web/Program.cs @@ -0,0 +1,20 @@ +using Microsoft.AspNetCore; +using Microsoft.AspNetCore.Hosting; + +namespace FilterLists.Web +{ + public class Program + { + public static void Main(string[] args) + { + BuildWebHost(args).Run(); + } + + public static IWebHost BuildWebHost(string[] args) + { + return WebHost.CreateDefaultBuilder(args) + .UseStartup() + .Build(); + } + } +} \ No newline at end of file diff --git a/src/FilterLists.Web/Startup.cs b/src/FilterLists.Web/Startup.cs new file mode 100644 index 000000000..94d89b2d8 --- /dev/null +++ b/src/FilterLists.Web/Startup.cs @@ -0,0 +1,37 @@ +using Microsoft.AspNetCore.Builder; +using Microsoft.AspNetCore.Hosting; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.DependencyInjection; + +namespace FilterLists.Web +{ + public class Startup + { + public Startup(IConfiguration configuration) + { + Configuration = configuration; + } + + public IConfiguration Configuration { get; } + + public void ConfigureServices(IServiceCollection services) + { + services.AddMvc(); + } + + public void Configure(IApplicationBuilder app, IHostingEnvironment env) + { + if (env.IsDevelopment()) + app.UseBrowserLink(); + + app.UseStaticFiles(); + + app.UseMvc(routes => + { + routes.MapRoute( + "default", + "{controller=Home}/{action=Index}/{id?}"); + }); + } + } +} \ No newline at end of file diff --git a/src/FilterLists.Web/Views/Home/Index.cshtml b/src/FilterLists.Web/Views/Home/Index.cshtml new file mode 100644 index 000000000..681b705c3 --- /dev/null +++ b/src/FilterLists.Web/Views/Home/Index.cshtml @@ -0,0 +1,3 @@ +@{ + ViewData["Title"] = "Home Page"; +} \ No newline at end of file