使用GraphiQL的MongoDB领域:嵌套对象属性上的空值(仅链接时)
我正在使用MongoDB领域接口中的GraphiQL 我的模型“Training”和“Buildind”中有2个实体 当我请求列出所有建筑物时,一切正常。 当我申请带有链接建筑的培训列表时,我没有度假的价值开始日期和结束日期 这是一个错误还是我在规则上遗漏了什么 培训模式: "title": "training", "properties": { "_id": { "bsonType": "objectId" }, "building": { "bsonType": "objectId" } (...) } } 建筑模式使用GraphiQL的MongoDB领域:嵌套对象属性上的空值(仅链接时),mongodb,graphql,Mongodb,Graphql,我正在使用MongoDB领域接口中的GraphiQL 我的模型“Training”和“Buildind”中有2个实体 当我请求列出所有建筑物时,一切正常。 当我申请带有链接建筑的培训列表时,我没有度假的价值开始日期和结束日期 这是一个错误还是我在规则上遗漏了什么 培训模式: "title": "training", "properties": { "_id": { "bsonType&
{
"title": "building",
"properties": {
"_id": {
"bsonType": "objectId"
},
"vacations": {
"bsonType": "array",
"items": {
"bsonType": "object",
"properties": {
"start_date": {
"bsonType": "date"
},
"end_date": {
"bsonType": "date"
}
}
}
},
(..)
}
}
你得到答案了吗?你得到答案了吗?
{
"title": "building",
"properties": {
"_id": {
"bsonType": "objectId"
},
"vacations": {
"bsonType": "array",
"items": {
"bsonType": "object",
"properties": {
"start_date": {
"bsonType": "date"
},
"end_date": {
"bsonType": "date"
}
}
}
},
(..)
}
}