Hi All,
I am trying to understand Asp.Net MVC with DDD following is the structure of application according to the http://aspnetdesignpatterns.codeplex.com/
Application Layers
Presentation Layer => MVC views,
Controllers(MVC) => MVC Controllers class,
Cached Service => ?,
Application Service => ?,
Domain Model => ?,
Repository => repository class to interact with DB,
Infrastructure => Class for logging, mailing etc.
here m having confusion in Application service and domain model, where should i fit my business logic (in service or in domain model)
what exactly should be in service and what should be in domain.
e.g suppose i want to add customer in DB how should be the flow..?
as i know,
in controller class i will write like
var customeService = new CustomeService (_customerRepository);
customeService.Add(customer);
if m wrong please correct me here..
_customerRepository goes in repository
what goes in model and what should be the flow of code.
please clear me. thanks in advance.