Click here to Skip to main content
14,387,112 members
Rate this:
Please Sign up or sign in to vote.
See more:
Create ASP.NET Core 2.2 Web Application(MVC) with Individual User Accounts.

In the _LoginPartial.cshtml file, there are something like this:
<a  class="nav-link text-dark" asp-area="Identity" asp-page="/Account/Manage/Index" title="Manage">


But there is no AccountController,the project only contains HomeController

How this action asp-page="/Account/Manage/Index" can be found in the file_LoginPartial.cshtml.

What I have tried:

I don't understand what's happen
Posted
Updated 29-May-19 22:58pm
v4
Rate this:
Please Sign up or sign in to vote.

Solution 1

These might help:

To include the files/ module your application need to customize, Right click your project in the solution explorer and choose Add > New Scaffolded Item, Select Identity, Add, check the files you want to customize and pick the DBContext.

Alternatively, If you want to see how the code work, for instance, Login, open the login.cshtml.cs under Areas, Identity, Pages, Account, Expand Login.cshtml. Then place a break point on OnPostAsync / OnGetAsync

asp.net identity - Where are the Login and Register pages in an AspNet Core scaffolded app? - Stack Overflow[^]

ASP.NET Blog | ASP.NET Core 2.1.0-preview1: Introducing Identity UI as a library[^]
   
v2
Rate this:
Please Sign up or sign in to vote.

Solution 2

The razor pages are embedded in the dll(s) that implement the identity functionality. You can override the pages.

Check the Microsoft dos at https:docs.microsft.com.
   
Comments
Richard Deeming 31-May-19 9:30am
   
Isn't that essentially what Bryian said back in February? It's certainly covered in the StackOverflow link he posted.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100