mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-11-08 18:34:55 +08:00
-
This commit is contained in:
@@ -125,6 +125,17 @@ namespace SqlSugar
|
||||
this.Context.Utilities.PageEach(allDatas, 300, itemList =>
|
||||
{
|
||||
List<IConditionalModel> conditList = new List<IConditionalModel>();
|
||||
SetConditList(itemList, whereColumns, conditList);
|
||||
var addItem = this.Context.Queryable<T>().Where(conditList).ToList();
|
||||
this.dbDataList.AddRange(addItem);
|
||||
});
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
private static void SetConditList(List<StorageableInfo<T>> itemList, List<EntityColumnInfo> whereColumns, List<IConditionalModel> conditList)
|
||||
{
|
||||
var condition = new ConditionalCollections()
|
||||
{
|
||||
ConditionalList = new List<KeyValuePair<WhereType, SqlSugar.ConditionalModel>>()
|
||||
@@ -138,15 +149,9 @@ namespace SqlSugar
|
||||
{
|
||||
FieldName = item.DbColumnName,
|
||||
ConditionalType = ConditionalType.Equal,
|
||||
FieldValue = item.PropertyInfo.GetValue(dataItem,null)+""
|
||||
FieldValue = item.PropertyInfo.GetValue(dataItem, null) + ""
|
||||
}));
|
||||
}
|
||||
var addItem = this.Context.Queryable<T>().Where(conditList).ToList();
|
||||
this.dbDataList.AddRange(addItem);
|
||||
}
|
||||
});
|
||||
}
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user