Reputation: 1057
I am new to ASP.NET MVC and as of right now I have the basic understanding of how MVC works. I have created a simple mvc website which uses only one project utilizing the pattern Model-View-Controller.
But I want to learn how to make an mvc web application that uses a specific architecture and having a hard time looking for references online to help me understand it.
I was given a project, to study, and rewrite it but I don't want to be copying each classes one by one without understanding how it's done, I plan to rewrite it from scratch and just use the existing project a guide.
What I need exactly is if someone can point me to where to start reading to understand this project's architecture:
ProjectSolution
Project.Web
//An MVC web application
Project.DataAccess
//An edmx file (database first)
Contracts
IRepository.cs
IUnitOfWork
Repositories
GenericRepository.cs
UnitOfWork
Project.Business
Contracts
IService1.cs
IService2.cs
....so on
Services
Service1.cs
Service2.cs
....so on
From just relying on my personal code reading capability, I can see that from this setup, it consists of 3 different projects, Project.Web is an MVC webapp, while the other 2 are Class Libraries.
Well, technically, I know how this architecture works, but I want to know how to make it from scratch, I mean, which ones are auto generated, which ones are written individually etc etc. And I also want to learn how ViewModel works, because inside Project.Web there is a folder ViewModels that represents a collection of models that is used in the view.
Gahh! I'm lost, I dont know where to start reading.
I don't need explanation on each but can you point me where to find a tutorial or something similar to this project for me to know how to build it. Please help! Thank you!
Note: I know this is not a proper question to be posted here but I am desperate and seeking help from the experienced ones to point me somewhere.
Upvotes: 1
Views: 467
Reputation: 2541
From the structure you posted it looks like the solution (One solution) has three different projects:
You mentioned that the 2 projects are class library projects and the Web is a WebSite project and this is an architecture i follow to organize my projects/solution.
Please note that this is an architecture design to organize your projects and in no way is the only or best one. but with any design you might follow try to respect the SoC (Separation of Concerns) goal of the MVC pattern.
Upvotes: 2