From 3c0534c8297e4beb8dbd03d7e2d39ac193311f33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E9=B9=8F?= Date: Fri, 28 Mar 2025 12:58:31 +0800 Subject: [PATCH] =?UTF-8?q?FastestProvider=20=E5=A2=9E=E5=8A=A0=20DbType.C?= =?UTF-8?q?ustom=20=E7=9A=84=20className=20=E5=AE=9A=E4=B9=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../SqlSugar/Abstract/FastestProvider/Private.cs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Src/Asp.NetCore2/SqlSugar/Abstract/FastestProvider/Private.cs b/Src/Asp.NetCore2/SqlSugar/Abstract/FastestProvider/Private.cs index 13aa763f9..cb5891328 100644 --- a/Src/Asp.NetCore2/SqlSugar/Abstract/FastestProvider/Private.cs +++ b/Src/Asp.NetCore2/SqlSugar/Abstract/FastestProvider/Private.cs @@ -12,6 +12,7 @@ namespace SqlSugar { private IFastBuilder GetBuider() { + var className = string.Empty; switch (this.context.CurrentConnectionConfig.DbType) { case DbType.MySql: @@ -45,11 +46,15 @@ namespace SqlSugar case DbType.Oscar: break; case DbType.QuestDB: - return new QuestDBFastBuilder(this.entityInfo); + return new QuestDBFastBuilder(this.entityInfo); + case DbType.Custom: + className = InstanceFactory.CustomNamespace + "." + InstanceFactory.CustomDbName + "FastBuilder"; + break; default: + className = $"SqlSugar.{this.context.CurrentConnectionConfig.DbType}FastBuilder"; break; } - var reslut = InstanceFactory.CreateInstance($"SqlSugar.{this.context.CurrentConnectionConfig.DbType}FastBuilder"); + var reslut = InstanceFactory.CreateInstance(className); reslut.CharacterSet = this.CharacterSet; reslut.FastEntityInfo = this.entityInfo; return reslut;