mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-19 10:08:19 +08:00
Update childDb.AsTenant()
This commit is contained in:
@@ -1663,10 +1663,17 @@ namespace SqlSugar
|
||||
|
||||
#region AsTenant
|
||||
public ITenant AsTenant()
|
||||
{
|
||||
if (this.Root != null)
|
||||
{
|
||||
return this.Root;
|
||||
}
|
||||
else
|
||||
{
|
||||
Check.Exception(true, ErrorMessage.GetThrowMessage("Child objects do not support tenant methods, var childDb= Db.GetConnection(confid) ,Db is master ", "Db子对象不支持租户方法,请使用主对象,例如:var childDb= Db.GetConnection(confid) Db是主对象,childDb是子对象 "));
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
Reference in New Issue
Block a user