mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-05 17:37:58 +08:00
Synchronization code
This commit is contained in:
parent
38b6a979ba
commit
2800f2483f
@ -37,6 +37,17 @@ namespace SqlSugar
|
||||
}
|
||||
return result;
|
||||
}
|
||||
public List<DbTableInfo> GetTableInfoList(Func<DbType,string, string> getChangeSqlFunc)
|
||||
{
|
||||
var db=this.Context.CopyNew();
|
||||
db.Aop.OnExecutingChangeSql = (sql, pars) =>
|
||||
{
|
||||
sql= getChangeSqlFunc(this.Context.CurrentConnectionConfig.DbType, sql);
|
||||
return new KeyValuePair<string, SugarParameter[]>(sql,pars);
|
||||
};
|
||||
var result= db.DbMaintenance.GetTableInfoList(false);
|
||||
return result;
|
||||
}
|
||||
public virtual List<DbTableInfo> GetTableInfoList(bool isCache = true)
|
||||
{
|
||||
string cacheKey = "DbMaintenanceProvider.GetTableInfoList"+this.Context.CurrentConnectionConfig.ConfigId;
|
||||
|
@ -13,6 +13,7 @@ namespace SqlSugar
|
||||
List<string> GetDataBaseList();
|
||||
List<DbTableInfo> GetViewInfoList(bool isCache=true);
|
||||
List<DbTableInfo> GetTableInfoList(bool isCache=true);
|
||||
List<DbTableInfo> GetTableInfoList(Func<DbType, string, string> getChangeSqlFunc);
|
||||
List<DbColumnInfo> GetColumnInfosByTableName(string tableName,bool isCache=true);
|
||||
List<string> GetIsIdentities(string tableName);
|
||||
List<string> GetPrimaries(string tableName);
|
||||
|
Loading…
Reference in New Issue
Block a user