这个页面描述了简单的读取。
但是,我不清楚是否支持_include (网页) (参见2.2.4.1章包含路径),以及是否还可以返回嵌套资源?
以下要求也是如此:
include=MedicationOrder.medication有效吗?
如果json的回应是:
{
"resourceType": "MedicationOrder",
"id": "5",
"detail" : "abc",
"medication":
{
"resourceType": "Medication",
"id": "example",
"otherDetails": "xyz"
}
}发布于 2015-09-18 07:58:54
仅作为搜索的一部分支持_include。所以
include=MedicationOrder.medication
是无效的。这是:
include=MedicationOrder:medication
如果有MedicationOrder和药物的话,你就可以拿回一包药。
您所称的“嵌套资源”--是指包含资源吗?--如果MedicationOrder中有包含的资源,那么它们总是与它一起返回--它们是它的一部分。但它们不会出现在药物中,正如你在上面的例子中所显示的那样。相反:
{
"resourceType": "MedicationOrder",
"id": "5",
"detail" : "abc",
"medication": {
"reference" : "#m1"
},
"contained": [
{
"resourceType": "Medication",
"id": "m1",
"otherDetails": "xyz"
}
]
}https://stackoverflow.com/questions/32640707
复制相似问题