mirror of
https://github.com/dotnetcore/FreeSql.git
synced 2026-02-05 16:00:52 +08:00
update
4
实体关系.md
4
实体关系.md
@@ -2,12 +2,12 @@
|
|||||||
|
|
||||||
```csharp
|
```csharp
|
||||||
//导航属性,OneToMany
|
//导航属性,OneToMany
|
||||||
[Navigate("song_id")]
|
[Navigate(nameof(song_tag.song_id))]
|
||||||
public virtual List<song_tag> Obj_song_tag { get; set; }
|
public virtual List<song_tag> Obj_song_tag { get; set; }
|
||||||
//在 song_tag 查找 song_id 属性,与 本实体.主键 关联
|
//在 song_tag 查找 song_id 属性,与 本实体.主键 关联
|
||||||
|
|
||||||
//导航属性,ManyToOne/OneToOne
|
//导航属性,ManyToOne/OneToOne
|
||||||
[Navigate("song_id")]
|
[Navigate(nameof(song_id))]
|
||||||
public virtual Song Obj_song { get; set; }
|
public virtual Song Obj_song { get; set; }
|
||||||
//在 本实体 查找 song_id 属性,与 Song.主键 关联
|
//在 本实体 查找 song_id 属性,与 Song.主键 关联
|
||||||
|
|
||||||
|
|||||||
2
联级保存.md
2
联级保存.md
@@ -47,7 +47,7 @@ class CagetoryParent
|
|||||||
public string Name { get; set; }
|
public string Name { get; set; }
|
||||||
|
|
||||||
public Guid ParentId { get; set; }
|
public Guid ParentId { get; set; }
|
||||||
[Navigate("ParentId")]
|
[Navigate(nameof(ParentId))]
|
||||||
public List<CagetoryParent> Childs { get; set; }
|
public List<CagetoryParent> Childs { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user