Skip to content

Commit

Permalink
Update Eexamples. Update project versions. Update referenced packages.
Browse files Browse the repository at this point in the history
  • Loading branch information
a-gubskiy committed Mar 22, 2020
1 parent 81700c4 commit 1d78902
Show file tree
Hide file tree
Showing 490 changed files with 210 additions and 104,609 deletions.
14 changes: 7 additions & 7 deletions X.PagedList.sln
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "X.PagedList.Tests", "tests\
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "X.PagedList.Mvc.Example", "examples\X.PagedList.Mvc.Example\X.PagedList.Mvc.Example.csproj", "{7DA46F0E-B5DD-4A4C-8B18-645101E1C3B0}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "X.PagedList.Mvc.Example.Core", "examples\X.PagedList.Mvc.Example.Core\X.PagedList.Mvc.Example.Core.csproj", "{89EA823D-1A1B-4569-B33B-A54CEFAFE480}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "X.PagedList.Web.Common", "src\X.PagedList.Web.Common\X.PagedList.Web.Common.csproj", "{A83A2188-D9AB-4A53-9888-D00EBCAC5160}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "X.PagedList.EF", "src\X.PagedList.EF\X.PagedList.EF.csproj", "{5D72EF31-35AD-4FB6-987A-5644B8CFD918}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "X.PagedList.EF.Tests", "tests\X.PagedList.EF.Tests\X.PagedList.EF.Tests.csproj", "{75367B5D-FB8B-4B1C-884C-DB52B316EB7C}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "X.PagedList.Mvc.Example.Core", "examples\X.PagedList.Mvc.Example.Core\X.PagedList.Mvc.Example.Core.csproj", "{288F5726-904F-48B8-8363-EA1A22D331D1}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand All @@ -53,10 +53,6 @@ Global
{7DA46F0E-B5DD-4A4C-8B18-645101E1C3B0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7DA46F0E-B5DD-4A4C-8B18-645101E1C3B0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7DA46F0E-B5DD-4A4C-8B18-645101E1C3B0}.Release|Any CPU.Build.0 = Release|Any CPU
{89EA823D-1A1B-4569-B33B-A54CEFAFE480}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{89EA823D-1A1B-4569-B33B-A54CEFAFE480}.Debug|Any CPU.Build.0 = Debug|Any CPU
{89EA823D-1A1B-4569-B33B-A54CEFAFE480}.Release|Any CPU.ActiveCfg = Release|Any CPU
{89EA823D-1A1B-4569-B33B-A54CEFAFE480}.Release|Any CPU.Build.0 = Release|Any CPU
{A83A2188-D9AB-4A53-9888-D00EBCAC5160}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A83A2188-D9AB-4A53-9888-D00EBCAC5160}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A83A2188-D9AB-4A53-9888-D00EBCAC5160}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -69,6 +65,10 @@ Global
{75367B5D-FB8B-4B1C-884C-DB52B316EB7C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{75367B5D-FB8B-4B1C-884C-DB52B316EB7C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{75367B5D-FB8B-4B1C-884C-DB52B316EB7C}.Release|Any CPU.Build.0 = Release|Any CPU
{288F5726-904F-48B8-8363-EA1A22D331D1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{288F5726-904F-48B8-8363-EA1A22D331D1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{288F5726-904F-48B8-8363-EA1A22D331D1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{288F5726-904F-48B8-8363-EA1A22D331D1}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand All @@ -79,10 +79,10 @@ Global
{3FB17E16-B671-450F-81BD-FD607D6A78C4} = {BDDADD09-D112-418E-8469-BC762EC09936}
{C78B1316-1EF9-45C3-A3FD-9A131BA3DD62} = {0170B742-C624-4C22-9DE1-2A93CF9C12D6}
{7DA46F0E-B5DD-4A4C-8B18-645101E1C3B0} = {309A8FC8-4784-4D8D-903F-BD54EBB0F1D7}
{89EA823D-1A1B-4569-B33B-A54CEFAFE480} = {309A8FC8-4784-4D8D-903F-BD54EBB0F1D7}
{A83A2188-D9AB-4A53-9888-D00EBCAC5160} = {BDDADD09-D112-418E-8469-BC762EC09936}
{5D72EF31-35AD-4FB6-987A-5644B8CFD918} = {BDDADD09-D112-418E-8469-BC762EC09936}
{75367B5D-FB8B-4B1C-884C-DB52B316EB7C} = {0170B742-C624-4C22-9DE1-2A93CF9C12D6}
{288F5726-904F-48B8-8363-EA1A22D331D1} = {309A8FC8-4784-4D8D-903F-BD54EBB0F1D7}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {1A82D446-6F26-48B2-8085-DFA5F87453FC}
Expand Down
3 changes: 0 additions & 3 deletions examples/X.PagedList.Mvc.Example.Core/.bowerrc

This file was deleted.

24 changes: 15 additions & 9 deletions examples/X.PagedList.Mvc.Example.Core/Program.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,26 @@
using System.IO;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;

namespace X.PagedList.Mvc.Example.Core
{
public class Program
{
public static void Main(string[] args)
{
var host = new WebHostBuilder()
.UseKestrel()
.UseContentRoot(Directory.GetCurrentDirectory())
.UseIISIntegration()
.UseStartup<Startup>()
.Build();

host.Run();
CreateHostBuilder(args).Build().Run();
}

public static IHostBuilder CreateHostBuilder(string[] args) =>
Host.CreateDefaultBuilder(args)
.ConfigureWebHostDefaults(webBuilder =>
{
webBuilder.UseStartup<Startup>();
});
}
}
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:49951/",
"sslPort": 0
"applicationUrl": "http://localhost:55924",
"sslPort": 44326
}
},
"profiles": {
Expand All @@ -16,7 +16,12 @@
}
},
"X.PagedList.Mvc.Example.Core": {
"commandName": "Project"
"commandName": "Project",
"launchBrowser": true,
"applicationUrl": "https://localhost:5001;http://localhost:5000",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}
}
43 changes: 22 additions & 21 deletions examples/X.PagedList.Mvc.Example.Core/Startup.cs
Original file line number Diff line number Diff line change
@@ -1,55 +1,56 @@
using Microsoft.AspNetCore.Builder;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.AspNetCore.HttpsPolicy;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Hosting;

namespace X.PagedList.Mvc.Example.Core
{
public class Startup
{
public Startup(IHostingEnvironment env)
public Startup(IConfiguration configuration)
{
var builder = new ConfigurationBuilder()
.SetBasePath(env.ContentRootPath)
.AddJsonFile("appsettings.json", optional: false, reloadOnChange: true)
.AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true)
.AddEnvironmentVariables();
Configuration = builder.Build();
Configuration = configuration;
}

public IConfigurationRoot Configuration { get; }
public IConfiguration Configuration { get; }

// This method gets called by the runtime. Use this method to add services to the container.
public void ConfigureServices(IServiceCollection services)
{
// Add framework services.
services.AddMvc();
services.AddControllersWithViews();
}

// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
loggerFactory.AddConsole(Configuration.GetSection("Logging"));
loggerFactory.AddDebug();

if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
app.UseBrowserLink();
}
else
{
app.UseExceptionHandler("/Home/Error");
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
app.UseHsts();
}

app.UseHttpsRedirection();
app.UseStaticFiles();

app.UseMvc(routes =>
app.UseRouting();

app.UseAuthorization();

app.UseEndpoints(endpoints =>
{
routes.MapRoute(
endpoints.MapControllerRoute(
name: "default",
template: "{controller=Home}/{action=Index}/{id?}");
pattern: "{controller=Home}/{action=Index}/{id?}");
});
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
@*import this so we can cast our list to IPagedList (only necessary because ViewBag is dynamic)*@

<!-- import the included stylesheet for some (very basic) default styling -->
<link href="/Content/PagedList.css" rel="stylesheet" type="text/css" />
<link href="/css/PagedList.css" rel="stylesheet" type="text/css" />

<!-- loop through each of your products and display it however you want. we're just printing the name here -->
<section class="mt-4">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@


<!-- import the included stylesheet for some (very basic) default styling -->
<link href="/Content/PagedList.css" rel="stylesheet" type="text/css" />
<link href="/css/PagedList.css" rel="stylesheet" type="text/css" />

<!-- loop through each of your products and display it however you want. we're just printing the name here -->
<h2>List of Products</h2>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,15 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>@ViewData["Title"] - X.PagedList.Mvc.Example.Core</title>

<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" />

<environment names="Development">
<link rel="stylesheet" href="~/lib/bootstrap-modern/dist/css/bootstrap.css" />
<link rel="stylesheet" href="~/css/site.css" />
<link rel="stylesheet" href="~/css/PagedList.css" />
</environment>
<environment names="Staging,Production">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
asp-fallback-href="~/lib/bootstrap-modern/dist/css/bootstrap.css"
asp-fallback-test-class="sr-only" asp-fallback-test-property="position" asp-fallback-test-value="absolute" />
<link rel="stylesheet" href="~/css/site.min.css" asp-append-version="true" />
<link rel="stylesheet" href="~/css/PagedList.css" />
</environment>
</head>
<body>
Expand Down Expand Up @@ -45,28 +44,12 @@
</footer>
</div>

<environment names="Development">
<script src="~/lib/jquery/dist/jquery.js"></script>
<script src="~/lib/bootstrap-modern/dist/js/bootstrap.js"></script>
<script src="~/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.js"></script>
<script src="~/js/site.js" asp-append-version="true"></script>
</environment>
<environment names="Staging,Production">
<script src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-2.2.0.min.js"
asp-fallback-src="~/lib/jquery/dist/jquery.min.js"
asp-fallback-test="window.jQuery"
crossorigin="anonymous"
integrity="sha384-K+ctZQ+LL8q6tP7I94W+qzQsfRV2a+AfHIi9k8z8l9ggpc8X+Ytst4yBo/hH+8Fk">
</script>
<script src="~/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.min.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js"
asp-fallback-src="~/lib/bootstrap-modern/dist/js/bootstrap.js"
asp-fallback-test="window.jQuery && window.jQuery.fn && window.jQuery.fn.modal"
crossorigin="anonymous"
integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy">
</script>
<script src="~/js/site.min.js" asp-append-version="true"></script>
</environment>
<script src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-2.2.0.min.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js"></script>
<script src="/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.js"></script>


<!--<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-validation-unobtrusive/3.2.4/jquery.validate.unobtrusive.js"></script>-->

@RenderSection("Scripts", required: false)
</body>
Expand Down
33 changes: 6 additions & 27 deletions examples/X.PagedList.Mvc.Example.Core/Views/Shared/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,12 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>@ViewData["Title"] - X.PagedList.Mvc.Example.Core</title>

<link rel="stylesheet" href="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/css/bootstrap.min.css" />
<environment names="Development">
<link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.css" />
<link rel="stylesheet" href="~/css/site.css" />
<link rel="stylesheet" href="~/css/PagedList.css" />
</environment>
<environment names="Staging,Production">
<link rel="stylesheet" href="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/css/bootstrap.min.css"
asp-fallback-href="~/lib/bootstrap/dist/css/bootstrap.min.css"
asp-fallback-test-class="sr-only" asp-fallback-test-property="position" asp-fallback-test-value="absolute" />
<link rel="stylesheet" href="~/css/site.min.css" asp-append-version="true" />
</environment>
</head>
Expand Down Expand Up @@ -46,29 +42,12 @@
<p>&copy; @DateTime.Now.Year - X.PagedList.Mvc.Example.Core</p>
</footer>
</div>

<script src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-2.2.0.min.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/bootstrap.min.js"></script>
<!--<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-validation-unobtrusive/3.2.11/jquery.validate.unobtrusive.min.js"></script>-->
<script src="/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.js"></script>

<environment names="Development">
<script src="~/lib/jquery/dist/jquery.js"></script>
<script src="~/lib/bootstrap/dist/js/bootstrap.js"></script>
<script src="~/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.js"></script>
<script src="~/js/site.js" asp-append-version="true"></script>
</environment>
<environment names="Staging,Production">
<script src="https://ajax.aspnetcdn.com/ajax/jquery/jquery-2.2.0.min.js"
asp-fallback-src="~/lib/jquery/dist/jquery.min.js"
asp-fallback-test="window.jQuery"
crossorigin="anonymous"
integrity="sha384-K+ctZQ+LL8q6tP7I94W+qzQsfRV2a+AfHIi9k8z8l9ggpc8X+Ytst4yBo/hH+8Fk">
</script>
<script src="~/lib/jquery-ajax-unobtrusive/jquery.unobtrusive-ajax.min.js"></script>
<script src="https://ajax.aspnetcdn.com/ajax/bootstrap/3.3.7/bootstrap.min.js"
asp-fallback-src="~/lib/bootstrap/dist/js/bootstrap.min.js"
asp-fallback-test="window.jQuery && window.jQuery.fn && window.jQuery.fn.modal"
crossorigin="anonymous"
integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa">
</script>
<script src="~/js/site.min.js" asp-append-version="true"></script>
</environment>

@RenderSection("Scripts", required: false)
</body>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>netcoreapp2.2</TargetFramework>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore" Version="2.2.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc" Version="2.2.0" />
<PackageReference Include="Microsoft.AspNetCore.StaticFiles" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="2.2.0" />
<PackageReference Include="Microsoft.VisualStudio.Web.BrowserLink" Version="2.2.0" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\src\X.PagedList.Mvc.Core\X.PagedList.Mvc.Core.csproj" />
<ProjectReference Include="..\..\src\X.PagedList\X.PagedList.csproj" />
</ItemGroup>



</Project>
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
{
{
"Logging": {
"IncludeScopes": false,
"LogLevel": {
"Default": "Debug",
"System": "Information",
"Microsoft": "Information"
"Default": "Information",
"Microsoft": "Warning",
"Microsoft.Hosting.Lifetime": "Information"
}
}
}
10 changes: 6 additions & 4 deletions examples/X.PagedList.Mvc.Example.Core/appsettings.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
{
{
"Logging": {
"IncludeScopes": false,
"LogLevel": {
"Default": "Warning"
"Default": "Information",
"Microsoft": "Warning",
"Microsoft.Hosting.Lifetime": "Information"
}
}
},
"AllowedHosts": "*"
}
12 changes: 0 additions & 12 deletions examples/X.PagedList.Mvc.Example.Core/bower.json

This file was deleted.

Loading

0 comments on commit 1d78902

Please sign in to comment.