ASP.NET MVC multi-site design -



ASP.NET MVC multi-site design -

i'm looking create new mvc site, , 1 of key problems i'm trying solve sharing code between public area (web-facing) , internal area.

basically have 2 applications, 1 public web site users access, , used internally @ our company view of same info visible on public site.

i want maintain them 2 separate sites (projects) because have different teams of people working on each, , because want utilize different authentication formats (forms public, windows internal).

however, want able share of code (views, controllers) between 2 sites. how set these 2 mvc sites such 1 mvc site reference view , / or controller in project?

for instance, have view enable internal users see transaction history of our public site users. if have created controller/view in internal site , later wanted add together in public site, how re-use same view on public site?

technically, others have said, can set want shared in class library project, , reference project other projects. views bit different as, in order share them between projects, have compile them. you'll need razor generator that.

practically, though, it's going rare view should shared between projects (aside layout), , virtually non-existent should share controller. if overlap great, it's argument 2 projects should not in fact 2 projects, one. controllers , views customized application sharing them doesn't create sense of time. thought share models , other classes.

asp.net asp.net-mvc

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -