mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-08-23 22:11:36 +08:00
Add unit test
This commit is contained in:
parent
63cc920a16
commit
76fd8b07a8
@ -261,7 +261,8 @@ namespace OrmTest
|
|||||||
.ThenInclude(z1 => z1.RoomList)
|
.ThenInclude(z1 => z1.RoomList)
|
||||||
.Include(z1 => z1.Books).ExecuteCommand();
|
.Include(z1 => z1.Books).ExecuteCommand();
|
||||||
|
|
||||||
|
db.Queryable<StudentA>()
|
||||||
|
.Where(it => it.Books2.Any(z => z.BookId == 1)).ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
public class UnitA001
|
public class UnitA001
|
||||||
@ -330,6 +331,9 @@ namespace OrmTest
|
|||||||
[Navigate(NavigateType.OneToMany, nameof(BookA.studenId))]
|
[Navigate(NavigateType.OneToMany, nameof(BookA.studenId))]
|
||||||
public List<BookA> Books { get; set; }
|
public List<BookA> Books { get; set; }
|
||||||
|
|
||||||
|
[Navigate(NavigateType.OneToMany, nameof(BookA.studenId),nameof(StudentId))]
|
||||||
|
public List<BookA> Books2 { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
public class SchoolA
|
public class SchoolA
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user