{
  "resourceType": "StructureDefinition",
  "id": "1e9a732a-ac09-4d30-88e5-697fc0c7a5bf",
  "meta": {
    "versionId": "1",
    "lastUpdated": "2019-10-29T10:29:19.461+00:00"
  },
  "url": "https://medico-emr.net/medico/r4/sd/CarePlan_CareInterventionPlan_1",
  "name": "CarePlan_CareInterventionPlan_1",
  "status": "draft",
  "date": "2019-10-29T10:29:19.305509Z",
  "description": "medico:  Please see implementation guide \"care intervention\"\r\n\r\nAn instance of this profile represents a care plan for one specific care intervention...\r\n   1.  within a specific period  (.period)\r\n   2.  with a specific interval    (.timing extension)\r\n   3.  targetting one specific care intervention  (activity.detail.code - where activity and detail both exist exactly 1 time)\r\n   4.  with a suggested duration  ((.timing extension)\r\n   5.  the care intervention belonging to a specific group (.category)\r\n   6.  the care intervention's reasoned problem group (.activity.detail.reasonCode)\r\n\r\nThe neccessity to document each care intervention (i.e. each Procedure) can be looked up through the .category (a slice exsits for this)\r\n\r\nthe content mainly maps to n1011sps - but in part also to n1010spl.",
  "fhirVersion": "4.0.0",
  "kind": "resource",
  "abstract": false,
  "type": "CarePlan",
  "baseDefinition": "https://medico-emr.net/medico/r4/sd/CarePlan_Base_1",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "CarePlan.id",
        "path": "CarePlan.id",
        "definition": "medico: Format: CareInterventionPlan-####   \r\n(number maps to N1011SPS)"
      },
      {
        "id": "CarePlan.meta.profile",
        "path": "CarePlan.meta.profile",
        "fixedCanonical": "https://medico-emr.net/medico/r4/sd/CarePlan_CareInterventionPlan_1"
      },
      {
        "id": "CarePlan.extension",
        "path": "CarePlan.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "CarePlan.extension:timing",
        "path": "CarePlan.extension",
        "sliceName": "timing",
        "max": "1",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://medico-emr.net/medico/r4/sd/ext/CarePlan_CareInterventionPlan_Timing_1"
            ]
          }
        ]
      },
      {
        "id": "CarePlan.identifier",
        "path": "CarePlan.identifier",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "system"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "CarePlan.identifier:medicoResourceId",
        "path": "CarePlan.identifier",
        "sliceName": "medicoResourceId"
      },
      {
        "id": "CarePlan.identifier:medicoResourceId.system",
        "path": "CarePlan.identifier.system",
        "comment": "Dynamically resolved for validation\r\n--FixedValue=https://medico-emr.net/medico/%KUNDE%/sid1/CareInterventionPlan"
      },
      {
        "id": "CarePlan.instantiatesCanonical",
        "path": "CarePlan.instantiatesCanonical",
        "definition": "Points to an ActivityDefinition resource (see ActivityDefinition_ActivityCareInterventionPlan_1) \r\nThat ActivityDefinition resource has to be used that has the same value in its \"url\"-field.",
        "min": 1,
        "max": "1"
      },
      {
        "id": "CarePlan.partOf",
        "path": "CarePlan.partOf",
        "max": "0"
      },
      {
        "id": "CarePlan.status",
        "path": "CarePlan.status",
        "definition": "medico supports active, cancelled, suspended, completed\r\nIt maps to n1010spl.status and n1010spl.discont\r\n  active        --> status=0 discont=0\r\n  cancelled --->   status=1   discont=0\r\n  completed -->  status=0  discont=1\r\n  suspended -->  status=1   discont=1"
      },
      {
        "id": "CarePlan.category",
        "path": "CarePlan.category",
        "slicing": {
          "discriminator": [
            {
              "type": "pattern",
              "path": "$this"
            }
          ],
          "rules": "open"
        },
        "definition": "CareInterventions are grouped by several ways:\r\n- CareInterventionGroup - Pflegemaßnahmengruppe\r\n- TopicGroup - Themengruppe\r\nOther relevant information that can be viewed as being gorup-information is also but into category",
        "constraint": [
          {
            "key": "medico-SystemAndCodeRequired",
            "severity": "error",
            "human": "System and Code are required",
            "expression": "children().system.exists() and children().code.exists()"
          }
        ]
      },
      {
        "id": "CarePlan.category:careInterventionGroup",
        "path": "CarePlan.category",
        "sliceName": "careInterventionGroup",
        "definition": "careInterventionGroup",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/%KUNDE%/cs/CareInterventionGroup"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:careInterventionGroup.coding.system",
        "path": "CarePlan.category.coding.system",
        "comment": "Dynamically resolved for validation\r\n--FixedValue=https://medico-emr.net/medico/%KUNDE%/cs/CareInterventionGroup"
      },
      {
        "id": "CarePlan.category:docDurationMandatory",
        "path": "CarePlan.category",
        "sliceName": "docDurationMandatory",
        "definition": "medico: Defines that each instance of Procedure_CareIntervention_1 need to provide a duration of the care intervention",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/cs1",
              "code": "DurationMandatory"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:docDurationMandatory.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/cs1"
      },
      {
        "id": "CarePlan.category:docDurationMandatory.coding.code",
        "path": "CarePlan.category.coding.code",
        "fixedCode": "DurationMandatory"
      },
      {
        "id": "CarePlan.category:docCommentMandatory",
        "path": "CarePlan.category",
        "sliceName": "docCommentMandatory",
        "definition": "medico: Defines that each instance of Procedure_CareIntervention_1 need to provide a comment of the care intervention",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/cs1",
              "code": "CommentMandatory"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:docCommentMandatory.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/cs1"
      },
      {
        "id": "CarePlan.category:docCommentMandatory.coding.code",
        "path": "CarePlan.category.coding.code",
        "fixedCode": "CommentMandatory"
      },
      {
        "id": "CarePlan.category:provenanceMandatory",
        "path": "CarePlan.category",
        "sliceName": "provenanceMandatory",
        "definition": "medico: Defines that each instance of Procedure_CareIntervention_1 should have a Provenance_CareInterventionProvenance_1 counter-part.\r\n(\"Teilnahmebestätigung\"). The provenance serves to confirm that nurses/male nurses participated in a care-intervention.",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/cs1",
              "code": "CareIntervention-ProvenanceMandatory"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:provenanceMandatory.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/cs1"
      },
      {
        "id": "CarePlan.category:provenanceMandatory.coding.code",
        "path": "CarePlan.category.coding.code",
        "fixedCode": "CareIntervention-ProvenanceMandatory"
      },
      {
        "id": "CarePlan.category:carePlanTopicHygiene",
        "path": "CarePlan.category",
        "sliceName": "carePlanTopicHygiene",
        "definition": "medico: Identifies a CarePlan as belonging to a certain relevant topic.\r\nCurrently only supported: \"Hygiene\"",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/cs1",
              "code": "CPTHygiene"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:carePlanTopicHygiene.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/cs1"
      },
      {
        "id": "CarePlan.category:carePlanTopicHygiene.coding.code",
        "path": "CarePlan.category.coding.code",
        "fixedCode": "CPTHygiene"
      },
      {
        "id": "CarePlan.category:topicGroups",
        "path": "CarePlan.category",
        "sliceName": "topicGroups",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/%KUNDE%/sid1/CareInterventionTopicGroup"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:topicGroups.coding.system",
        "path": "CarePlan.category.coding.system",
        "comment": "Dynamically resolved for validation\r\n--FixedValue=https://medico-emr.net/medico/%KUNDE%/sid1/CareInterventionTopicGroup"
      },
      {
        "id": "CarePlan.category:docDocumentationMandatory",
        "path": "CarePlan.category",
        "sliceName": "docDocumentationMandatory",
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/cs1",
              "code": "DocumentationMandatory"
            }
          ]
        }
      },
      {
        "id": "CarePlan.category:docDocumentationMandatory.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/cs1"
      },
      {
        "id": "CarePlan.category:docDocumentationMandatory.coding.code",
        "path": "CarePlan.category.coding.code",
        "fixedCode": "DocumentationMandatory"
      },
      {
        "id": "CarePlan.category:planningType",
        "path": "CarePlan.category",
        "sliceName": "planningType",
        "min": 1,
        "max": "1",
        "patternCodeableConcept": {
          "coding": [
            {
              "system": "https://medico-emr.net/medico/cs/CarePlanPlanningType"
            }
          ]
        },
        "binding": {
          "strength": "preferred",
          "valueSet": "https://medico-emr.net/medico/r4/vs/CarePlan_PlanningType_1"
        }
      },
      {
        "id": "CarePlan.category:planningType.coding.system",
        "path": "CarePlan.category.coding.system",
        "fixedUri": "https://medico-emr.net/medico/cs/CarePlanPlanningType"
      },
      {
        "id": "CarePlan.category:planningType.coding.display",
        "path": "CarePlan.category.coding.display",
        "max": "0"
      },
      {
        "id": "CarePlan.title",
        "path": "CarePlan.title",
        "definition": "Plain text name for the care intervention(Pflegemassnahme)\r\nmaps to n7010srv.des",
        "min": 1
      },
      {
        "id": "CarePlan.description",
        "path": "CarePlan.description",
        "max": "0"
      },
      {
        "id": "CarePlan.period.start",
        "path": "CarePlan.period.start",
        "definition": "The start of the period. The boundary is inclusive.\r\nAlways beginning of a day - i.e. time is 00:00:00"
      },
      {
        "id": "CarePlan.period.end",
        "path": "CarePlan.period.end",
        "definition": "Always end of the same day as start - i.e. 23:59:59",
        "min": 1
      },
      {
        "id": "CarePlan.author",
        "path": "CarePlan.author",
        "min": 1,
        "max": "1"
      },
      {
        "id": "CarePlan.author.reference",
        "path": "CarePlan.author.reference",
        "min": 1
      },
      {
        "id": "CarePlan.author.type",
        "path": "CarePlan.author.type",
        "min": 1,
        "fixedUri": "Practitioner"
      },
      {
        "id": "CarePlan.author.identifier",
        "path": "CarePlan.author.identifier",
        "max": "0"
      },
      {
        "id": "CarePlan.author.display",
        "path": "CarePlan.author.display",
        "min": 1
      },
      {
        "id": "CarePlan.activity",
        "path": "CarePlan.activity",
        "min": 1,
        "max": "1"
      },
      {
        "id": "CarePlan.activity.progress",
        "path": "CarePlan.activity.progress",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail",
        "path": "CarePlan.activity.detail",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.id",
        "path": "CarePlan.activity.detail.id",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.kind",
        "path": "CarePlan.activity.detail.kind",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.instantiatesCanonical",
        "path": "CarePlan.activity.detail.instantiatesCanonical",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.code",
        "path": "CarePlan.activity.detail.code",
        "definition": "medico: refers to n7070srv.srv",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.code.id",
        "path": "CarePlan.activity.detail.code.id",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.code.coding",
        "path": "CarePlan.activity.detail.code.coding",
        "min": 1,
        "max": "1"
      },
      {
        "id": "CarePlan.activity.detail.code.coding.id",
        "path": "CarePlan.activity.detail.code.coding.id",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.code.coding.system",
        "path": "CarePlan.activity.detail.code.coding.system",
        "definition": "medico: System has this pattern:\r\nhttps://medico-emr.net/medico/%KUNDE%/cs/CareInterventionCodeSystem-{n1100mdc.cat}",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.code.coding.version",
        "path": "CarePlan.activity.detail.code.coding.version",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.code.coding.code",
        "path": "CarePlan.activity.detail.code.coding.code",
        "definition": "medico: maps to n1100mdc.srv",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.code.coding.userSelected",
        "path": "CarePlan.activity.detail.code.coding.userSelected",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.code.text",
        "path": "CarePlan.activity.detail.code.text",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode",
        "path": "CarePlan.activity.detail.reasonCode",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "coding.system"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup",
        "path": "CarePlan.activity.detail.reasonCode",
        "sliceName": "problemGroup"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.id",
        "path": "CarePlan.activity.detail.reasonCode.id",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding",
        "path": "CarePlan.activity.detail.reasonCode.coding",
        "min": 1,
        "max": "1"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.id",
        "path": "CarePlan.activity.detail.reasonCode.coding.id",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.system",
        "path": "CarePlan.activity.detail.reasonCode.coding.system",
        "definition": "Dynamically resolved for validation\r\n--FixedValue=https://medico-emr.net/medico/%KUNDE%/sid1/CareInterventionProblemGroup",
        "comment": "Dynamically resolved for validation\r\n--FixedValue=https://medico-emr.net/medico/%KUNDE%/sid1/CareInterventionProblemGroup",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.version",
        "path": "CarePlan.activity.detail.reasonCode.coding.version",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.code",
        "path": "CarePlan.activity.detail.reasonCode.coding.code",
        "definition": "medico: maps to n1010spl.prg",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.display",
        "path": "CarePlan.activity.detail.reasonCode.coding.display",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.coding.userSelected",
        "path": "CarePlan.activity.detail.reasonCode.coding.userSelected",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonCode:problemGroup.text",
        "path": "CarePlan.activity.detail.reasonCode.text",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.reasonReference",
        "path": "CarePlan.activity.detail.reasonReference",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.status",
        "path": "CarePlan.activity.detail.status",
        "definition": "medico: this property does not bear useful information",
        "fixedCode": "unknown"
      },
      {
        "id": "CarePlan.activity.detail.statusReason",
        "path": "CarePlan.activity.detail.statusReason",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.performer",
        "path": "CarePlan.activity.detail.performer",
        "definition": "medico: CarePlans for care intervention - usually in the planning phase nurse/male nurses are not known, i.e. this field might be empty"
      },
      {
        "id": "CarePlan.activity.detail.performer.reference",
        "path": "CarePlan.activity.detail.performer.reference",
        "min": 1
      },
      {
        "id": "CarePlan.activity.detail.performer.identifier",
        "path": "CarePlan.activity.detail.performer.identifier",
        "max": "0"
      },
      {
        "id": "CarePlan.activity.detail.quantity",
        "path": "CarePlan.activity.detail.quantity",
        "max": "0"
      },
      {
        "id": "CarePlan.note.extension",
        "path": "CarePlan.note.extension",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "url"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "CarePlan.note.extension:specialDocumentation",
        "path": "CarePlan.note.extension",
        "sliceName": "specialDocumentation",
        "type": [
          {
            "code": "Extension",
            "profile": [
              "https://medico-emr.net/medico/r4/sd/ext/Annotation_SpecialDocumentation_1"
            ]
          }
        ]
      },
      {
        "id": "CarePlan.note.author[x]",
        "path": "CarePlan.note.author[x]",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "https://medico-emr.net/medico/r4/sd/Practitioner_User_1"
            ]
          }
        ]
      }
    ]
  }
}