PackagesCanonicalsLogsProblems
    Packages
    hl7.fhir.r4.id.core@0.1.0
    https://fhir.kemkes.go.id/r4/StructureDefinition/Questionnaire
description: A structured set of questions intended to guide the collection of answers from end-users. Questionnaires provide detailed control over order, presentation, phraseology and grouping to allow coherent, consistent data collection.
package_name: hl7.fhir.r4.id.core
derivation: specialization
name: Questionnaire
type: Questionnaire
elements:
  description: {type: markdown, short: Natural language description of the questionnaire, index: 12}
  subjectType:
    short: Resource that can be subject of QuestionnaireResponse
    type: code
    binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/resource-types|4.0.1'}
    isSummary: true
    index: 8
  date: {short: Date last changed, type: dateTime, isSummary: true, index: 9}
  publisher: {short: Name of the publisher (organization or individual), type: string, isSummary: true, index: 10}
  approvalDate: {type: date, short: When the questionnaire was approved by publisher, index: 17}
  jurisdiction:
    short: Intended jurisdiction for questionnaire (if applicable)
    type: CodeableConcept
    binding: {strength: extensible, valueSet: 'http://hl7.org/fhir/ValueSet/jurisdiction'}
    isSummary: true
    index: 14
  derivedFrom: {type: canonical, short: Instantiates protocol or definition, index: 5}
  purpose: {type: markdown, short: Why this questionnaire is defined, index: 15}
  name: {short: Name for this questionnaire (computer friendly), type: string, isSummary: true, index: 3}
  item:
    constraint:
      que-6: {human: Required and repeat aren't permitted for display items, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: type!='display' or (required.empty() and repeats.empty())}
      que-3: {human: Display items cannot have a "code" asserted, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: type!='display' or code.empty()}
      que-4: {human: A question cannot have both answerOption and answerValueSet, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: answerOption.empty() or answerValueSet.empty()}
      que-8: {human: Initial values can't be specified for groups or display items, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: (type!='group' and type!='display') or initial.empty()}
      que-13: {human: Can only have multiple initial values for repeating items, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: repeats=true or initial.count() <= 1}
      que-12: {human: 'If there are more than one enableWhen, enableBehavior must be specified', source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: enableWhen.count() > 2 implies enableBehavior.exists()}
      que-11: {human: 'If one or more answerOption is present, initial[x] must be missing', source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: answerOption.empty() or initial.empty()}
      que-9: {human: Read-only can't be specified for "display" items, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: type!='display' or readOnly.empty()}
      que-1: {human: 'Group items must have nested items, display items cannot have nested items', source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: (type='group' implies item.empty().not()) and (type.trace('type')='display' implies item.trace('item').empty())}
      que-10: {human: Maximum length can only be declared for simple question types, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: (type in ('boolean' | 'decimal' | 'integer' | 'string' | 'text' | 'url' | 'open-choice')) or maxLength.empty()}
      que-5: {human: Only 'choice' and 'open-choice' items can have answerValueSet, source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: (type ='choice' or type = 'open-choice' or type = 'decimal' or type = 'integer' or type = 'date' or type = 'dateTime' or type = 'time' or type = 'string' or type = 'quantity') or (answerValueSet.empty() and answerOption.empty())}
    short: Questions and sections within the Questionnaire
    type: BackboneElement
    index: 21
    elements:
      enableBehavior:
        short: all | any
        type: code
        binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/questionnaire-enable-behavior|4.0.1'}
        index: 43
      definition: {short: ElementDefinition - details for the item, type: uri, index: 23}
      linkId: {short: Unique id for item in questionnaire, type: string, index: 22}
      repeats: {short: Whether the item may repeat, type: boolean, meaningWhenMissing: Items are generally assumed not to repeat unless explicitly specified. Systems SHOULD always populate this value, index: 45}
      item:
        elementReference: ['https://fhir.kemkes.go.id/r4/StructureDefinition/Questionnaire', elements, item]
        short: Nested questionnaire items
        array: true
        index: 74
      type:
        short: group | display | boolean | decimal | integer | date | dateTime +
        type: code
        binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/item-type|4.0.1'}
        index: 27
      enableWhen:
        constraint:
          que-7: {human: 'If the operator is ''exists'', the value must be a boolean', source: 'http://hl7.org/fhir/StructureDefinition/Questionnaire', severity: error, expression: operator = 'exists' implies (answer is Boolean)}
        isModifier: true
        short: Only allow data when
        type: BackboneElement
        isModifierReason: If enableWhen is present and the condition evaluates to false, then the Questionnaire behaves as though the elements weren't actually present
        index: 28
        elements:
          answerQuantity: {short: Value for question comparison based on operator, type: Quantity, choiceOf: answer, index: 41}
          answerDecimal: {short: Value for question comparison based on operator, type: decimal, choiceOf: answer, index: 34}
          answerDate: {short: Value for question comparison based on operator, type: date, choiceOf: answer, index: 36}
          answerReference:
            short: Value for question comparison based on operator
            refers: ['http://hl7.org/fhir/StructureDefinition/Resource']
            type: Reference
            choiceOf: answer
            index: 42
          answerInteger: {short: Value for question comparison based on operator, type: integer, choiceOf: answer, index: 35}
          question: {short: Question that determines whether item is enabled, type: string, index: 29}
          answerDateTime: {short: Value for question comparison based on operator, type: dateTime, choiceOf: answer, index: 37}
          answer:
            short: Value for question comparison based on operator
            choices: [answerBoolean, answerDecimal, answerInteger, answerDate, answerDateTime, answerTime, answerString, answerCoding, answerQuantity, answerReference]
            index: 32
          answerString: {short: Value for question comparison based on operator, type: string, choiceOf: answer, index: 39}
          operator:
            short: exists | = | != | > | < | >= | <=
            type: code
            binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/questionnaire-enable-operator|4.0.1'}
            index: 30
          answerBoolean: {short: Value for question comparison based on operator, type: boolean, choiceOf: answer, index: 33}
          answerCoding: {short: Value for question comparison based on operator, type: Coding, choiceOf: answer, index: 40}
          answerTime: {short: Value for question comparison based on operator, type: time, choiceOf: answer, index: 38}
        required: [answerReference, operator, answerDate, answerTime, answerString, answerCoding, question, answerInteger, answerQuantity, answerDateTime, answerBoolean, answerDecimal, answer]
      answerOption:
        type: BackboneElement
        short: Permitted answer
        index: 49
        elements:
          value:
            short: Answer value
            choices: [valueInteger, valueDate, valueTime, valueString, valueCoding, valueReference]
            index: 51
          valueInteger: {short: Answer value, type: integer, choiceOf: value, index: 52}
          valueDate: {short: Answer value, type: date, choiceOf: value, index: 53}
          valueTime: {short: Answer value, type: time, choiceOf: value, index: 54}
          valueString: {short: Answer value, type: string, choiceOf: value, index: 55}
          valueCoding: {short: Answer value, type: Coding, choiceOf: value, index: 56}
          valueReference:
            short: Answer value
            refers: ['http://hl7.org/fhir/StructureDefinition/Resource']
            type: Reference
            choiceOf: value
            index: 57
          initialSelected: {short: Whether option is selected by default, type: boolean, meaningWhenMissing: Only selected items explicitly marked to be selected, index: 58}
        required: [valueCoding, valueString, valueReference, value, valueDate, valueTime, valueInteger]
      prefix: {short: 'E.g. "1(a)", "2.5.3"', type: string, index: 25}
      readOnly: {short: Don't allow human editing, type: boolean, index: 46}
      answerValueSet: {short: Valueset containing permitted answers, type: canonical, index: 48}
      code:
        short: Corresponding concept for this item in a terminology
        type: Coding
        binding: {strength: example, valueSet: 'http://hl7.org/fhir/ValueSet/questionnaire-questions'}
        index: 24
      initial:
        short: Initial value(s) when item is first rendered
        type: BackboneElement
        index: 59
        elements:
          valueReference:
            short: Actual value for initializing the question
            refers: ['http://hl7.org/fhir/StructureDefinition/Resource']
            type: Reference
            choiceOf: value
            index: 73
          valueUri: {short: Actual value for initializing the question, type: uri, choiceOf: value, index: 69}
          valueTime: {short: Actual value for initializing the question, type: time, choiceOf: value, index: 67}
          valueDecimal: {short: Actual value for initializing the question, type: decimal, choiceOf: value, index: 63}
          valueQuantity: {short: Actual value for initializing the question, type: Quantity, choiceOf: value, index: 72}
          value:
            short: Actual value for initializing the question
            choices: [valueBoolean, valueDecimal, valueInteger, valueDate, valueDateTime, valueTime, valueString, valueUri, valueAttachment, valueCoding, valueQuantity, valueReference]
            index: 61
          valueString: {short: Actual value for initializing the question, type: string, choiceOf: value, index: 68}
          valueBoolean: {short: Actual value for initializing the question, type: boolean, choiceOf: value, index: 62}
          valueDateTime: {short: Actual value for initializing the question, type: dateTime, choiceOf: value, index: 66}
          valueDate: {short: Actual value for initializing the question, type: date, choiceOf: value, index: 65}
          valueCoding: {short: Actual value for initializing the question, type: Coding, choiceOf: value, index: 71}
          valueInteger: {short: Actual value for initializing the question, type: integer, choiceOf: value, index: 64}
          valueAttachment: {short: Actual value for initializing the question, type: Attachment, choiceOf: value, index: 70}
        required: [valueCoding, valueUri, valueString, valueReference, valueDecimal, valueAttachment, valueDateTime, value, valueBoolean, valueDate, valueTime, valueQuantity, valueInteger]
      maxLength: {short: No more than this many characters, type: integer, index: 47}
      required: {short: Whether the item must be included in data results, type: boolean, meaningWhenMissing: Items are generally assumed not to be required unless explicitly specified. Systems SHOULD always populate this value, index: 44}
      text: {type: string, short: Primary text for the item, index: 26}
    required: [type, linkId]
  useContext: {short: The context that the content is intended to support, type: UsageContext, isSummary: true, index: 13}
  copyright: {short: Use and/or publishing restrictions, type: markdown, index: 16}
  experimental: {short: 'For testing purposes, not real usage', type: boolean, isSummary: true, index: 7}
  title: {short: Name for this questionnaire (human friendly), type: string, isSummary: true, index: 4}
  status:
    isModifier: true
    short: draft | active | retired | unknown
    type: code
    binding: {strength: required, valueSet: 'http://hl7.org/fhir/ValueSet/publication-status|4.0.1'}
    isModifierReason: This is labeled as "Is Modifier" because applications should not use a retired {{title}} without due consideration
    isSummary: true
    index: 6
  url: {short: 'Canonical identifier for this questionnaire, represented as a URI (globally unique)', type: uri, isSummary: true, index: 0}
  code:
    short: Concept that represents the overall questionnaire
    type: Coding
    binding: {strength: example, valueSet: 'http://hl7.org/fhir/ValueSet/questionnaire-questions'}
    isSummary: true
    index: 20
  identifier: {short: Additional identifier for the questionnaire, type: Identifier, isSummary: true, index: 1}
  lastReviewDate: {short: When the questionnaire was last reviewed, type: date, index: 18}
  version: {short: Business version of the questionnaire, type: string, isSummary: true, index: 2}
  contact: {type: ContactDetail, short: Contact details for the publisher, isSummary: true, index: 11}
  effectivePeriod: {short: When the questionnaire is expected to be used, type: Period, isSummary: true, index: 19}
package_version: 0.1.0
class: resource
kind: resource
url: https://fhir.kemkes.go.id/r4/StructureDefinition/Questionnaire
base: http://hl7.org/fhir/StructureDefinition/DomainResource
version: 4.0.1
required: [status]