Base solution for your next web application

Activities of "vincedc"

Answer

<cite>hikalkan: </cite>

So, all *.mydomain.com requests are redirected to the same app on iis. Then I get tenant name from URL.

I am sorry. Does your solution is implemented by using special route configuration? Or do you simply parse the url to extract the subdomain.

<cite>Omar: </cite> You should be able to change the name of your table during OnModelCreating. You can overwrite DataAnnotation of the table name . Code-First gives precedence to Fluent API > data annotations > default conventions.

protected override void OnModelCreating(DbModelBuilder modelBuilder)
       {
 
           modelBuilder.Entity<AuditLog>().ToTable("AuditLogs ");
                   
       }

How to handle the derived entities which actually are mapped with Table-per-type strategy? For example, in the default project

RolePermissionSetting

and

UserPermissionSetting

are both mapped to

AbpPermissions

table. How can we mapped these inheritance relationships?

Hi,

I am encountering a problem when restoring packages in the Web (other projects are not affected by this) project when using Visual Studio 2015. The problem happens without writing any line of code just on the template downloaded from the web site. This is the sequence of steps I am doing:

  1. Setup a project of type Multi Page Web Application on the site [http://aspnetboilerplate.com/Templates])
  2. Open the Package Manager Console ancd click on the restore packages. This produce the following log (I have only included the interested rows)
Attempting to gather dependencies information for multiple packages with respect to project 'MyCompany.MyProject.Web', targeting '.NETFramework,Version=v4.5.2'
Attempting to resolve dependencies for multiple packages
Resolving actions install multiple packages
[...]
Removed package 'Castle.Windsor-log4net 3.3.0' from 'packages.config'
Successfully uninstalled 'Castle.Windsor-log4net 3.3.0' from MyCompany.MyProject.Web
Removed package 'Castle.Core-log4net 3.3.3' from 'packages.config'
Successfully uninstalled 'Castle.Core-log4net 3.3.3' from MyCompany.MyProject.Web
Removed package 'log4net 1.2.10' from 'packages.config'
Successfully uninstalled 'log4net 1.2.10' from MyCompany.MyProject.Web
[...]
Adding package 'log4net.2.0.5' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.2.0.5' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.2.0.5' to 'packages.config'
Successfully installed 'log4net 2.0.5' to MyCompany.MyProject.Web
Adding package 'Castle.Core-log4net.3.0.0.4002' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.0.0.4002' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.0.0.4002' to 'packages.config'
Successfully installed 'Castle.Core-log4net 3.0.0.4002' to MyCompany.MyProject.Web
Adding package 'Castle.Windsor-log4net.3.0.0.4001', which only has dependencies, to project 'MyCompany.MyProject.Web'.
Adding package 'Castle.Windsor-log4net.3.0.0.4001' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.0.0.4001' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.0.0.4001' to 'packages.config'
Successfully installed 'Castle.Windsor-log4net 3.0.0.4001' to MyCompany.MyProject.Web
[...]
========== Finished ==========
  1. When the update finish it runs again automatically and this time presents three package to update. I have run the update and this is the log produced
Attempting to gather dependencies information for multiple packages with respect to project 'MyCompany.MyProject.Web', targeting '.NETFramework,Version=v4.5.2'
Attempting to resolve dependencies for multiple packages
Resolving actions install multiple packages
Removed package 'Castle.Windsor-log4net 3.0.0.4001' from 'packages.config'
Successfully uninstalled 'Castle.Windsor-log4net 3.0.0.4001' from MyCompany.MyProject.Web
Removed package 'Castle.Core-log4net 3.0.0.4002' from 'packages.config'
Successfully uninstalled 'Castle.Core-log4net 3.0.0.4002' from MyCompany.MyProject.Web
Removed package 'log4net 2.0.5' from 'packages.config'
Successfully uninstalled 'log4net 2.0.5' from MyCompany.MyProject.Web
Adding package 'log4net.1.2.10' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.1.2.10' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.1.2.10' to 'packages.config'
Successfully installed 'log4net 1.2.10' to MyCompany.MyProject.Web
Adding package 'Castle.Core-log4net.3.3.3' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.3.3' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.3.3' to 'packages.config'
Successfully installed 'Castle.Core-log4net 3.3.3' to MyCompany.MyProject.Web
Adding package 'Castle.Windsor-log4net.3.3.0', which only has dependencies, to project 'MyCompany.MyProject.Web'.
Adding package 'Castle.Windsor-log4net.3.3.0' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.3.0' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.3.0' to 'packages.config'
Successfully installed 'Castle.Windsor-log4net 3.3.0' to MyCompany.MyProject.Web
Removing package 'Castle.Windsor-log4net 3.0.0.4001' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'Castle.Windsor-log4net 3.0.0.4001' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removing package 'Castle.Core-log4net 3.0.0.4002' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'Castle.Core-log4net 3.0.0.4002' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removing package 'log4net 2.0.5' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'log4net 2.0.5' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
========== Finished ==========
  1. again when this update finish it runs again automatically and says that a apckage needs to be updated. If you run the update from this moment step 3 and step 4 repeat continuosly.
Attempting to gather dependencies information for multiple packages with respect to project 'MyCompany.MyProject.Web', targeting '.NETFramework,Version=v4.5.2'
Attempting to resolve dependencies for multiple packages
Resolving actions install multiple packages
Removed package 'Castle.Windsor-log4net 3.3.0' from 'packages.config'
Successfully uninstalled 'Castle.Windsor-log4net 3.3.0' from MyCompany.MyProject.Web
Removed package 'Castle.Core-log4net 3.3.3' from 'packages.config'
Successfully uninstalled 'Castle.Core-log4net 3.3.3' from MyCompany.MyProject.Web
Removed package 'log4net 1.2.10' from 'packages.config'
Successfully uninstalled 'log4net 1.2.10' from MyCompany.MyProject.Web
Adding package 'log4net.2.0.5' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.2.0.5' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'log4net.2.0.5' to 'packages.config'
Successfully installed 'log4net 2.0.5' to MyCompany.MyProject.Web
Adding package 'Castle.Core-log4net.3.0.0.4002' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.0.0.4002' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Core-log4net.3.0.0.4002' to 'packages.config'
Successfully installed 'Castle.Core-log4net 3.0.0.4002' to MyCompany.MyProject.Web
Adding package 'Castle.Windsor-log4net.3.0.0.4001', which only has dependencies, to project 'MyCompany.MyProject.Web'.
Adding package 'Castle.Windsor-log4net.3.0.0.4001' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.0.0.4001' to folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Added package 'Castle.Windsor-log4net.3.0.0.4001' to 'packages.config'
Successfully installed 'Castle.Windsor-log4net 3.0.0.4001' to MyCompany.MyProject.Web
Removing package 'Castle.Windsor-log4net 3.3.0' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'Castle.Windsor-log4net 3.3.0' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removing package 'Castle.Core-log4net 3.3.3' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'Castle.Core-log4net 3.3.3' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removing package 'log4net 1.2.10' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
Removed package 'log4net 1.2.10' from folder 'D:\VisualStudio\MyCompany.MyProject\master\src\packages'
========== Finished ==========

I think that the problem depends on the log4net 2.0.5 version which I am not able to find on the log4net web site. Could you please suggest how to solve this problem?

Thanks a lot and keep up the great work! ;)

Best regards

Update: Any help on this? Any suggestion?

Showing 1 to 3 of 3 entries