|
|
@@ -10,8 +10,9 @@ namespace Admin.NET.Core;
|
|
|
/// <typeparam name="T"></typeparam>
|
|
|
public class SqlSugarRepository<T> : SimpleClient<T> where T : class, new()
|
|
|
{
|
|
|
- public SqlSugarRepository(ITenant iTenant)
|
|
|
+ public SqlSugarRepository()
|
|
|
{
|
|
|
+ var iTenant = App.GetRequiredService<ISqlSugarClient>().AsTenant();
|
|
|
base.Context = iTenant.GetConnectionScope(SqlSugarConst.MainConfigId);
|
|
|
|
|
|
// 若实体贴有多库特性,则返回指定库连接
|