mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-05-17 21:49:33 +08:00
Update InstanceFactory
This commit is contained in:
parent
5be180bc48
commit
5bc23c8d0f
@ -2,6 +2,7 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
namespace SqlSugar
|
||||
@ -364,14 +365,30 @@ namespace SqlSugar
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
{
|
||||
return new InsertableProvider<T>();
|
||||
}
|
||||
}
|
||||
|
||||
private static bool IsCustomDb(ConnectionConfig currentConnectionConfig)
|
||||
{
|
||||
return currentConnectionConfig.DbType==DbType.Custom;
|
||||
if (currentConnectionConfig.DbType == DbType.Custom)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return currentConnectionConfig.DbType != DbType.SqlServer &&
|
||||
currentConnectionConfig.DbType != DbType.Dm &&
|
||||
currentConnectionConfig.DbType != DbType.Oscar &&
|
||||
currentConnectionConfig.DbType != DbType.Access &&
|
||||
currentConnectionConfig.DbType != DbType.QuestDB &&
|
||||
currentConnectionConfig.DbType != DbType.MySql &&
|
||||
currentConnectionConfig.DbType != DbType.Oracle &&
|
||||
currentConnectionConfig.DbType != DbType.PostgreSQL &&
|
||||
currentConnectionConfig.DbType != DbType.ClickHouse &&
|
||||
currentConnectionConfig.DbType != DbType.GBase &&
|
||||
currentConnectionConfig.DbType != DbType.Sqlite &&
|
||||
GetCustomTypeByClass("SqlSugar." + currentConnectionConfig.DbType + "." + currentConnectionConfig.DbType + "Provider") != null;
|
||||
|
||||
}
|
||||
|
||||
public static IDbBind GetDbBind(ConnectionConfig currentConnectionConfig)
|
||||
|
Loading…
Reference in New Issue
Block a user