For a formbuilder project I am currently working on I want to be able to add it to different websites without the need to duplicate code. Each website has a different page structure and layout. But all websites must be able to log in to the same formbuilder project. The domain name for each website is different.
对于我目前正在开发的formbuilder项目,我希望能够将其添加到不同的网站,而不需要重复代码。每个网站都有不同的页面结构和布局。但是所有的网站都必须能够登录到同一个formbuilder项目。每个网站的域名都是不同的。
This is my current Solution layout:
这是我目前的解决方案布局:
Solution 1 website http://www.domain1.com
解决方案1网站http://www.domain1.com
- DAL.dll (Formbuilder data access)
- 木豆。dll(Formbuilder数据访问)
- Business.dll (Formbuilder logic)
- 业务。dll(Formbuilder逻辑)
- Web (contains website and formbuilder controllers/views)
- Web(包含网站和formbuilder控制器/视图)
Solution 2 website http://www.anotherdomain.com
解决方案2网站http://www.anotherdomain.com
- DAL.dll (Formbuilder data access)
- 木豆。dll(Formbuilder数据访问)
- Business.dll (Formbuilder logic)
- 业务。dll(Formbuilder逻辑)
- Web (contains website and formbuilder controllers/views)
- Web(包含网站和formbuilder控制器/视图)
The problem with this solution layout is that for each website I add the same formbuilder controllers and views. When I have to change the formbuilder I need to make the same change on each website. Is there a way to add the formbuilder as one module to my websites?
这个解决方案布局的问题是,我为每个网站添加了相同的formbuilder控制器和视图。当我需要更改formbuilder时,我需要在每个网站上进行相同的更改。是否有办法将formbuilder作为一个模块添加到我的网站?
1 个解决方案
#1
1
Consider using MVC Areas to separate the code within the same website project.
考虑使用MVC区域来分离同一个网站项目中的代码。
Getting Started With Areas in MVC5
从MVC5中的区域开始
#1
1
Consider using MVC Areas to separate the code within the same website project.
考虑使用MVC区域来分离同一个网站项目中的代码。
Getting Started With Areas in MVC5
从MVC5中的区域开始