I have a question about architecture in .NET.
My architecture is like this :
Projet :
- DAL (Data Acces Layer)
- BLL (Business Logic Layer)
- DTO (Data Transfer Object)
- IHM (man/machine interface)
DAL : Acces to the database (CRUD) It reference DTO
BLL : Logic Layer do all logic process and make the connection between IHM and DAL. This layer reference DAL and DTO
IHM : Presentation Layer (asp MVC) this layer has a reference on BLL and DTO
DTO : I put EDMX (Entity Data Model) in this layer (cross cutting)
My question is about the EDMX. I put it in DTO layer in order to make accessible the object to all other layer. In my IHM layer I map DTO's object with ViewModel to send to the view only the field needed
I see in other project they put the EDMX in DAL but they create object in each layer and map them. It's unpleasing and it's code duplication.
Is it bad to put EDMX in DTO and why ?
Regards