InvalidOperationException: Cannot create a DbSet for 'IdentityUserClaim' because this type is not included in the model for the context.

An unhandled exception occurred while processing the request.

InvalidOperationException: Cannot create a DbSet for 'IdentityUserClaim' because this type is not included in the model for the context.

Microsoft.EntityFrameworkCore.Internal.InternalDbSet.get_EntityType()

 

解决方法,Context继承identitycontext,不要自己实现集合,让他自动创建

你可能感兴趣的:(InvalidOperationException: Cannot create a DbSet for 'IdentityUserClaim' because this type is not included in the model for the context.)