U
uran1
In MVP (Model-View-Presenter) presenter shouldn;t depend on view
layer(so it cannot contain reference to System.Web)- we cannot use
Membershi and Role providers in Preseneter (Controlling layer). Access
to those objects is posible only in view, where should be no logic
(business logic).
How to solve this problem - does view should pass information about
currently logged user (using MembershipProvider to dermine who is
logged)- allow acces to these information to presenter through view
interface? Then presenter could decide whether to show or not
information and pass data to view; That aproach makes using ASP.NET
login (and other 'native' ) asp controls limited.
The similar problem is how to generate website menu- using SiteMap
based on RoleProvider (in sitemap xml we define which roles are allowed
to view which pages)m we can automaticlly hide som menu options, which
are not avaialable to currentyl logged user, by this aproach (again)
need to place some business logic in aspx file (which is in view
layer).
What is the solution , which let use use handy asp.net control?maybe
yet another pattern?
layer(so it cannot contain reference to System.Web)- we cannot use
Membershi and Role providers in Preseneter (Controlling layer). Access
to those objects is posible only in view, where should be no logic
(business logic).
How to solve this problem - does view should pass information about
currently logged user (using MembershipProvider to dermine who is
logged)- allow acces to these information to presenter through view
interface? Then presenter could decide whether to show or not
information and pass data to view; That aproach makes using ASP.NET
login (and other 'native' ) asp controls limited.
The similar problem is how to generate website menu- using SiteMap
based on RoleProvider (in sitemap xml we define which roles are allowed
to view which pages)m we can automaticlly hide som menu options, which
are not avaialable to currentyl logged user, by this aproach (again)
need to place some business logic in aspx file (which is in view
layer).
What is the solution , which let use use handy asp.net control?maybe
yet another pattern?