将NuGetGallery升级EF6之后,遭遇这样的错误:
Method not found: 'System.Data.Objects.ObjectContext
System.Data.Entity.Infrastructure.IObjectContextAdapter.get_ObjectContext()'.
如何解决这个问题?
卸载DynamicData.EFCodeFirstProvider,安装Microsoft ASP.NET DynamicData EFProvider:
PM> Uninstall-Package DynamicData.EFCodeFirstProvider
PM> Install-Package Microsoft.AspNet.DynamicData.EFProvider
在NuGetGallery的代码中将
EFCodeFirstDataModelProvider
改为
Microsoft.AspNet.DynamicData.ModelProviders.EFDataModelProvider