【问题标题】:FHIR contained practionner in generalPractitionerFHIR 包含从业者一般从业者
【发布时间】:2016-12-27 23:27:59
【问题描述】:

在(最后一个)FHIR 规范 (v1.8.0) 中提到,当不存在引用时,包含资源可以嵌入到 Reference (documentation) 中。

但是,通过查看 XSD,我无法弄清楚如何使用这样的机制针对 patient.xsd 验证 XML。

这是我的尝试

<?xml version="1.0" encoding="UTF-8"?>
<Patient xmlns="http://hl7.org/fhir">
    <identifier>
        <system value="urn:oid:1.2.250.1.311.1.1"/>
        <value value="2000100439"/>
        <assigner>
            <display value="ap-hm"/>
        </assigner>
    </identifier>
    <name>
        <use value="official"/>
        <family value="COPTER"/>
        <given value="ELI"/>
    </name>
    <gender value="male"/>
    <birthDate value="1954-08-14"/>
    <deceasedBoolean value="false"/>
    <address>
        <use value="home"/>
        <line value="45 boulevard des cigales"/>
        <city value="MARSEILLE 10"/>
        <postalCode value="13010"/>
    </address>
    <maritalStatus>
        <coding>
            <system value="http://hl7.org/fhir/v3/MaritalStatus"/>
            <code value="U"/>
        </coding>
    </maritalStatus>
    <generalPractitioner>
        <contained>
            <Practitioner>
                <id value="p1"/>
                <name>
                    <family value="PASTEUR"/>
                    <given value="LOUIS"/>
                </name>
                <address>
                    <city>MARSEILLE</city>
                    <postalCode>13005</postalCode>
                </address>
                <gender value="male"/>
            </Practitioner>
        </contained>
    </generalPractitioner>
</Patient>

包含引用的正确方法是什么?

【问题讨论】:

    标签: hl7-fhir


    【解决方案1】:

    所有包含的资源都使用“包含”元素发送到靠近顶部的位置。然后将它们作为本地参考进行引用。因此,您的示例如下所示:

    <?xml version="1.0" encoding="UTF-8"?>
    <Patient xmlns="http://hl7.org/fhir">
        <contained>
            <Practitioner>
                <id value="p1"/>
                <name>
                    <family value="PASTEUR"/>
                    <given value="LOUIS"/>
                </name>
                <address>
                    <city>MARSEILLE</city>
                    <postalCode>13005</postalCode>
                </address>
                <gender value="male"/>
            </Practitioner>
        </contained>
        <identifier>
            <system value="urn:oid:1.2.250.1.311.1.1"/>
            <value value="2000100439"/>
            <assigner>
                <display value="ap-hm"/>
            </assigner>
        </identifier>
        <name>
            <use value="official"/>
            <family value="COPTER"/>
            <given value="ELI"/>
        </name>
        <gender value="male"/>
        <birthDate value="1954-08-14"/>
        <deceasedBoolean value="false"/>
        <address>
            <use value="home"/>
            <line value="45 boulevard des cigales"/>
            <city value="MARSEILLE 10"/>
            <postalCode value="13010"/>
        </address>
        <maritalStatus>
            <coding>
                <system value="http://hl7.org/fhir/v3/MaritalStatus"/>
                <code value="U"/>
            </coding>
        </maritalStatus>
        <generalPractitioner>
            <reference value="#p1"/>
        </generalPractitioner>
    </Patient>
    

    【讨论】:

    • 好吧劳埃德,这是有道理的。谢谢。或许可以在规范中加一句(hl7.org/fhir/2017Jan/references.html#Reference),说明在 DomainResource 中定义了 contains,然后根据 schema 必须在开头。
    • 对 city 和 postalCode 元素进行了另一项更改,例如 而不是 13005,XML 文档验证。
    • 欢迎对规范提出澄清建议。提出建议的最佳方式是单击规范中每个页面底部的“提出更改”链接。有一个一次性注册过程,之后您可以根据想法提交任何您希望的更改。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-11-18
    • 1970-01-01
    • 2015-01-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多