Avatar of CubeRoot
CubeRoot
Flag for United States of America

asked on 

MVC3 Entity Framework Solution with Seperate Projects

I've been working on understanding MVC3 with Entity Framework for a couple of weeks now. I'm sure I'll have more questions in the coming days but for now. I found some articles that suggest keeping my Entity framework, Interfaces, Business Logic, and the Main MVC site all in seperate projects in the same solution. I've got this all setup and it's builds with no issues. I'm ready to define the DBContext and I'm not sure where to place the references.

My Project looks like this:

MyBusinessLogic (Added References: MyInterfaces, MyEntityModel)
MyEntityModel
MyInterfaces
MyWebsite (Added References: MyInterfaces, MyBusinessLogic)

Where do I put the DBContext file and do I need to do anything special to communicate between the website, the businesslogic, and the entityframework?

I'm also very interested if there are any books on mvc3 that use this same approach where it has the seperate projects and outlines the development process?
C#

Avatar of undefined
Last Comment
Avodah

8/22/2022 - Mon