asp.net mvc module wise approach or different controller and repository for each table approach is better?
+1
A:
Hello,
Could you elaborate on your question? I think I understand... I like creating a repository for each table in a LINQ-to-SQL or entities model, for instance. I think that helps group together related logic.
HTH.
Brian
2010-05-18 12:51:09
well in traditional classes one is trying to bundle thing differently.like different table logic in different classes .in controllers do we ought to bundle things up or make different controllers for different tables. what we should do?
mazhar kaunain baig
2010-05-18 16:17:50
In my app, MVC controllers are tied to functional logic, while the repository to get or modify the data is specific to a table. That way, the repository groups the table-specific queries/modifications, but the controller may tie together multiple tables to display in the view... so that shouldn't be tied to a tabls, IMHO.
Brian
2010-05-18 16:56:29