{
  "resourceType": "StructureDefinition",
  "id": "86bce1b6-f4c0-4405-a8fd-0b44dd9b5791",
  "meta": {
    "lastUpdated": "2022-11-07T03:38:42.5902377+00:00"
  },
  "url": "https://simplifier.net/winningtest/service-invoice-profile",
  "name": "ServiceInvoice",
  "title": "服务收费/退费信息",
  "status": "draft",
  "date": "2022-11-07T03:38:56.0892151+00:00",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "v2",
      "uri": "http://hl7.org/v2",
      "name": "HL7 v2 Mapping"
    },
    {
      "identity": "rim",
      "uri": "http://hl7.org/v3",
      "name": "RIM Mapping"
    },
    {
      "identity": "w5",
      "uri": "http://hl7.org/fhir/fivews",
      "name": "FiveWs Pattern Mapping"
    },
    {
      "identity": "workflow",
      "uri": "http://hl7.org/fhir/workflow",
      "name": "Workflow Pattern"
    }
  ],
  "kind": "resource",
  "abstract": false,
  "type": "Invoice",
  "baseDefinition": "https://simplifier.net/winningtest/invoice-profile",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Invoice.identifier:requisition",
        "path": "Invoice.identifier",
        "sliceName": "requisition",
        "short": "申请单标识",
        "max": "1"
      },
      {
        "id": "Invoice.identifier:requisition.use",
        "path": "Invoice.identifier.use",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisition.type",
        "path": "Invoice.identifier.type",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisition.system",
        "path": "Invoice.identifier.system",
        "short": "申请单标识",
        "fixedUri": "urn:oid:1.2.156.112604.1.1.4699"
      },
      {
        "id": "Invoice.identifier:requisition.period",
        "path": "Invoice.identifier.period",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisition.assigner",
        "path": "Invoice.identifier.assigner",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisitionNo",
        "path": "Invoice.identifier",
        "sliceName": "requisitionNo",
        "short": "申请单编号",
        "max": "1"
      },
      {
        "id": "Invoice.identifier:requisitionNo.use",
        "path": "Invoice.identifier.use",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisitionNo.type",
        "path": "Invoice.identifier.type",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisitionNo.system",
        "path": "Invoice.identifier.system",
        "short": "申请单编号",
        "fixedUri": "urn:oid:1.2.156.112604.1.1.287"
      },
      {
        "id": "Invoice.identifier:requisitionNo.period",
        "path": "Invoice.identifier.period",
        "max": "0"
      },
      {
        "id": "Invoice.identifier:requisitionNo.assigner",
        "path": "Invoice.identifier.assigner",
        "max": "0"
      },
      {
        "id": "Invoice.status",
        "path": "Invoice.status",
        "definition": "issued表示申请中，balanced表示已收费/已退费，cancelled表示已撤销"
      },
      {
        "id": "Invoice.status.extension",
        "path": "Invoice.status.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "rules": "open"
        },
        "min": 0
      },
      {
        "id": "Invoice.status.extension:reason",
        "path": "Invoice.status.extension",
        "sliceName": "reason",
        "short": "状态说明",
        "min": 0,
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://simplifier.net/winningtest/extension-status-reason"
            ]
          }
        ]
      },
      {
        "id": "Invoice.cancelledReason",
        "path": "Invoice.cancelledReason",
        "max": "0"
      },
      {
        "id": "Invoice.type",
        "path": "Invoice.type",
        "max": "0"
      },
      {
        "id": "Invoice.subject",
        "path": "Invoice.subject",
        "max": "0",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "http://hl7.org/fhir/StructureDefinition/Patient"
            ]
          }
        ]
      },
      {
        "id": "Invoice.recipient",
        "path": "Invoice.recipient",
        "max": "0"
      },
      {
        "id": "Invoice.date",
        "path": "Invoice.date",
        "short": "申请时间"
      },
      {
        "id": "Invoice.participant",
        "path": "Invoice.participant",
        "max": "1"
      },
      {
        "id": "Invoice.participant.role.coding",
        "path": "Invoice.participant.role.coding",
        "max": "0"
      },
      {
        "id": "Invoice.participant.role.text",
        "path": "Invoice.participant.role.text",
        "short": "角色名称",
        "definition": "当为退费申请时，固定值为“退费申请人”"
      },
      {
        "id": "Invoice.participant.actor",
        "path": "Invoice.participant.actor",
        "short": "参与者",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "https://simplifier.net/winningtest/practitioner-profile"
            ],
            "aggregation": [
              "contained"
            ]
          }
        ]
      },
      {
        "id": "Invoice.issuer",
        "path": "Invoice.issuer",
        "max": "0"
      },
      {
        "id": "Invoice.account",
        "path": "Invoice.account",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "https://simplifier.net/winningtest/account-profile"
            ]
          }
        ]
      },
      {
        "id": "Invoice.lineItem.extension",
        "path": "Invoice.lineItem.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "rules": "open"
        },
        "min": 0
      },
      {
        "id": "Invoice.lineItem.extension:collated",
        "path": "Invoice.lineItem.extension",
        "sliceName": "collated",
        "short": "核对",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://simplifier.net/winningtest/extension-collated"
            ]
          }
        ]
      },
      {
        "id": "Invoice.lineItem.extension:chargeClassification",
        "path": "Invoice.lineItem.extension",
        "sliceName": "chargeClassification",
        "short": "价格分类",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://simplifier.net/winningtest/extension-charge-classification"
            ]
          }
        ]
      },
      {
        "id": "Invoice.lineItem.extension:selfAffordRatio",
        "path": "Invoice.lineItem.extension",
        "sliceName": "selfAffordRatio",
        "short": "自负比例",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://simplifier.net/winningtest/extension-self-afford-ratio"
            ]
          }
        ]
      },
      {
        "id": "Invoice.lineItem.chargeItem[x]",
        "path": "Invoice.lineItem.chargeItem[x]",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "https://simplifier.net/winningtest/service-charge-item-profile"
            ],
            "aggregation": [
              "contained"
            ]
          }
        ]
      },
      {
        "id": "Invoice.lineItem.priceComponent",
        "path": "Invoice.lineItem.priceComponent",
        "max": "1"
      },
      {
        "id": "Invoice.lineItem.priceComponent.code",
        "path": "Invoice.lineItem.priceComponent.code",
        "max": "0"
      },
      {
        "id": "Invoice.lineItem.priceComponent.factor",
        "path": "Invoice.lineItem.priceComponent.factor",
        "max": "0"
      },
      {
        "id": "Invoice.totalNet",
        "path": "Invoice.totalNet",
        "short": "订单总计金额"
      },
      {
        "id": "Invoice.totalGross",
        "path": "Invoice.totalGross",
        "max": "0"
      },
      {
        "id": "Invoice.paymentTerms",
        "path": "Invoice.paymentTerms",
        "max": "0"
      }
    ]
  }
}