From 2269a3198393f4edcc0ff7f515742a73c0c6881f Mon Sep 17 00:00:00 2001 From: Javier Calvarro Nelson Date: Sun, 21 Jan 2018 14:50:55 -0800 Subject: [PATCH] [Fixes #245] Update Identity to use the default layout from the application. Added /Areas/Identity/Pages/_ViewStart.cshtml and set the layout to the applications layout. --- .../RazorPagesWeb-CSharp/.template.config/template.json | 3 ++- .../Areas/Identity/Pages/_ViewStart.cshtml | 3 +++ .../Pages/{ => Shared}/_CookieConsentPartial.cshtml | 0 .../content/StarterWeb-CSharp/.template.config/template.json | 3 ++- .../StarterWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml | 3 +++ 5 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml rename src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/{ => Shared}/_CookieConsentPartial.cshtml (100%) create mode 100644 src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml diff --git a/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/.template.config/template.json b/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/.template.config/template.json index 82587c523d..39e8cfbcea 100644 --- a/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/.template.config/template.json +++ b/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/.template.config/template.json @@ -56,7 +56,8 @@ { "condition": "(!IndividualLocalAuth)", "exclude": [ - "Data/**" + "Data/**", + "Areas/**" ] }, { diff --git a/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml b/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml new file mode 100644 index 0000000000..0df6d39f62 --- /dev/null +++ b/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml @@ -0,0 +1,3 @@ +@{ + Layout = "/Pages/_Layout.cshtml"; +} diff --git a/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/_CookieConsentPartial.cshtml b/src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/Shared/_CookieConsentPartial.cshtml similarity index 100% rename from src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/_CookieConsentPartial.cshtml rename to src/Microsoft.DotNet.Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/Shared/_CookieConsentPartial.cshtml diff --git a/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/.template.config/template.json b/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/.template.config/template.json index e8d29882f2..299446e972 100644 --- a/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/.template.config/template.json +++ b/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/.template.config/template.json @@ -49,7 +49,8 @@ { "condition": "(!IndividualAuth)", "exclude": [ - "Data/**" + "Data/**", + "Areas/**" ] }, { diff --git a/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml b/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml new file mode 100644 index 0000000000..c4284f6c20 --- /dev/null +++ b/src/Microsoft.DotNet.Web.ProjectTemplates/content/StarterWeb-CSharp/Areas/Identity/Pages/_ViewStart.cshtml @@ -0,0 +1,3 @@ +@{ + Layout = "/Views/Shared/_Layout.cshtml"; +}