diff --git a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs index 9fa957ce6..8ada607bf 100644 --- a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs +++ b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs @@ -16,7 +16,7 @@ namespace SqlSugar #region T1 public partial class QueryableProvider : QueryableAccessory, ISugarQueryable { - public ISqlSugarClient Context { get; set; } + public SqlSugarProvider Context { get; set; } public IAdo Db { get { return Context.Ado; } } public IDbBind Bind { get { return this.Db.DbBind; } } public ISqlBuilder SqlBuilder { get; set; } diff --git a/Src/Asp.Net/SqlSugar/CacheScheme/CacheKeyBuider.cs b/Src/Asp.Net/SqlSugar/CacheScheme/CacheKeyBuider.cs index 52ff7a8a2..856a06863 100644 --- a/Src/Asp.Net/SqlSugar/CacheScheme/CacheKeyBuider.cs +++ b/Src/Asp.Net/SqlSugar/CacheScheme/CacheKeyBuider.cs @@ -7,7 +7,7 @@ namespace SqlSugar { internal class CacheKeyBuider { - public static CacheKey GetKey(ISqlSugarClient context, QueryBuilder queryBuilder) + public static CacheKey GetKey(SqlSugarProvider context, QueryBuilder queryBuilder) { CacheKey result = new CacheKey(); result.Database = context.Context.Ado.Connection.Database; diff --git a/Src/Asp.Net/SqlSugar/CacheScheme/CacheSchemeMain.cs b/Src/Asp.Net/SqlSugar/CacheScheme/CacheSchemeMain.cs index 5e5d9de6f..edec0a6e2 100644 --- a/Src/Asp.Net/SqlSugar/CacheScheme/CacheSchemeMain.cs +++ b/Src/Asp.Net/SqlSugar/CacheScheme/CacheSchemeMain.cs @@ -7,7 +7,7 @@ namespace SqlSugar { internal class CacheSchemeMain { - public static T GetOrCreate(ICacheService cacheService, QueryBuilder queryBuilder, Func getData, int cacheDurationInSeconds, ISqlSugarClient context) + public static T GetOrCreate(ICacheService cacheService, QueryBuilder queryBuilder, Func getData, int cacheDurationInSeconds, SqlSugarProvider context) { CacheKey key = CacheKeyBuider.GetKey(context, queryBuilder); string keyString = key.ToString(); diff --git a/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs b/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs index ed1989871..1eb4c906c 100644 --- a/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs +++ b/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs @@ -11,7 +11,7 @@ namespace SqlSugar { public partial interface ISugarQueryable { - ISqlSugarClient Context { get; set; } + SqlSugarProvider Context { get; set; } ISqlBuilder SqlBuilder { get; set; } QueryBuilder QueryBuilder { get; set; } ISugarQueryable Clone(); diff --git a/Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs b/Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs index 39a824dc6..4b550b646 100644 --- a/Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs +++ b/Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs @@ -23,7 +23,7 @@ namespace SqlSugar IAdo Ado { get; } AopProvider Aop { get; } ICodeFirst CodeFirst { get; } - SqlSugarProvider Context { get; set; } + IDbFirst DbFirst { get; } IDbMaintenance DbMaintenance { get; } diff --git a/Src/Asp.Net/SqlSugar/SqlSugarClient.cs b/Src/Asp.Net/SqlSugar/SqlSugarClient.cs index d521cce34..6a858ed2e 100644 --- a/Src/Asp.Net/SqlSugar/SqlSugarClient.cs +++ b/Src/Asp.Net/SqlSugar/SqlSugarClient.cs @@ -45,7 +45,7 @@ namespace SqlSugar #endregion #region Global variable - public SqlSugarProvider Context { get => GetContext(); set => _Context = value; } + public SqlSugarProvider Context { get => GetContext();} public bool IsSystemTablesConfig => this.Context.IsSystemTablesConfig; public ConnectionConfig CurrentConnectionConfig { get => _CurrentConnectionConfig; set => _CurrentConnectionConfig = value; } public Guid ContextID { get => this.Context.ContextID; set => this.Context.ContextID = value; }