mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-04-22 02:32:50 +08:00
update test
This commit is contained in:
parent
0341f69ed9
commit
a7b40e9a5a
@ -559,5 +559,14 @@
|
|||||||
<param name="that"></param>
|
<param name="that"></param>
|
||||||
<returns></returns>
|
<returns></returns>
|
||||||
</member>
|
</member>
|
||||||
|
<member name="M:Microsoft.Extensions.DependencyInjection.FreeSqlRepositoryDependencyInjection.AddFreeRepository(Microsoft.Extensions.DependencyInjection.IServiceCollection,System.Action{FreeSql.FluentDataFilter},System.Reflection.Assembly[])">
|
||||||
|
<summary>
|
||||||
|
批量注入 Repository,可以参考代码自行调整
|
||||||
|
</summary>
|
||||||
|
<param name="services"></param>
|
||||||
|
<param name="globalDataFilter"></param>
|
||||||
|
<param name="assemblies"></param>
|
||||||
|
<returns></returns>
|
||||||
|
</member>
|
||||||
</members>
|
</members>
|
||||||
</doc>
|
</doc>
|
||||||
|
@ -1913,9 +1913,9 @@ WHERE (((cast(a.""ID"" as blob sub_type 1)) in (SELECT FIRST 10 b.""TITLE""
|
|||||||
Assert.Equal("110100", t4[2].item.Code);
|
Assert.Equal("110100", t4[2].item.Code);
|
||||||
Assert.Equal("110101", t4[3].item.Code);
|
Assert.Equal("110101", t4[3].item.Code);
|
||||||
Assert.Equal("中国", t4[0].path);
|
Assert.Equal("中国", t4[0].path);
|
||||||
Assert.Equal("中国 -> 北京", t4[1].path);
|
Assert.Equal("中国 -> 北京 ", t4[1].path);
|
||||||
Assert.Equal("中国 -> 北京 -> 北京市", t4[2].path);
|
Assert.Equal("中国 -> 北京 -> 北京市", t4[2].path);
|
||||||
Assert.Equal("中国 -> 北京 -> 东城区", t4[3].path);
|
Assert.Equal("中国 -> 北京 -> 东城区", t4[3].path);
|
||||||
|
|
||||||
t4 = fsql.Select<VM_District_Child>().Where(a => a.Name == "中国").AsTreeCte(a => a.Name + "[" + a.Code + "]").OrderBy(a => a.Code)
|
t4 = fsql.Select<VM_District_Child>().Where(a => a.Name == "中国").AsTreeCte(a => a.Name + "[" + a.Code + "]").OrderBy(a => a.Code)
|
||||||
.ToList(a => new { item = a, level = Convert.ToInt32("a.cte_level"), path = "a.cte_path" });
|
.ToList(a => new { item = a, level = Convert.ToInt32("a.cte_level"), path = "a.cte_path" });
|
||||||
@ -1925,9 +1925,9 @@ WHERE (((cast(a.""ID"" as blob sub_type 1)) in (SELECT FIRST 10 b.""TITLE""
|
|||||||
Assert.Equal("110100", t4[2].item.Code);
|
Assert.Equal("110100", t4[2].item.Code);
|
||||||
Assert.Equal("110101", t4[3].item.Code);
|
Assert.Equal("110101", t4[3].item.Code);
|
||||||
Assert.Equal("中国[100000]", t4[0].path);
|
Assert.Equal("中国[100000]", t4[0].path);
|
||||||
Assert.Equal("中国[100000] -> 北京[110000]", t4[1].path);
|
Assert.Equal("中国[100000] -> 北京 [110000]", t4[1].path);
|
||||||
Assert.Equal("中国[100000] -> 北京[110000] -> 北京市[110100]", t4[2].path);
|
Assert.Equal("中国[100000] -> 北京 [110000] -> 北京市[110100]", t4[2].path);
|
||||||
Assert.Equal("中国[100000] -> 北京[110000] -> 东城区[110101]", t4[3].path);
|
Assert.Equal("中国[100000] -> 北京 [110000] -> 东城区[110101]", t4[3].path);
|
||||||
|
|
||||||
var select = fsql.Select<VM_District_Child>()
|
var select = fsql.Select<VM_District_Child>()
|
||||||
.Where(a => a.Name == "中国")
|
.Where(a => a.Name == "中国")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user