用例:我想调用返回嵌套子DTO对象的顶级(父)DTO。
实体示例:
entity Person {
firstName String
lastName String
}
entity Dog {
petName String
}
relationship OneToMany {
Person{dog} to Dog{person required}
}
生成的PersonDTO不包含DogDTO。我希望它返回以下内容:
{
"id": 1,
"firstName": "John",
"lastName": "Doe",
"dogs":
[
{
"id": 1
"petName": "Fido"
},
{
"id": 2
"petName": "Spot"
}
]
}
谢谢