FHIR © HL7.org  |  FHIRsmith 4.0.1  |  Server Home  |  XIG Home  |  XIG Stats  | 

FHIR IG analytics

Packagecsiro.fhir.au.smartforms
Resource TypeQuestionnaire
IdQuestionnaire-SubstanceUse.json
FHIR VersionR4
Sourcehttps://build.fhir.org/ig/aehrc/smart-forms-ig/Questionnaire-SubstanceUse.html
URLhttp://www.health.gov.au/assessments/mbs/715/SubstanceUse
Version0.4.0
Statusdraft
Date2025-03-14
NameSubstanceUse
TitleAboriginal and Torres Strait Islander Health Check - Substance Use
Realmau
CopyrightCopyright © 2022+ Australian Government Department of Health and Aged Care - All rights reserved. This content is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. See https://creativecommons.org/licenses/by-sa/4.0/.

Resources that use this resource

No resources found


Resources that this resource uses

No resources found


Narrative

Note: links and images are rebased to the (stated) source

Generated Narrative: Questionnaire SubstanceUse

Structure
LinkIDTextCardinalityTypeFlagsDescription & Constraintsdoco
.. SubstanceUseQuestionnairehttp://www.health.gov.au/assessments/mbs/715/SubstanceUse#0.4.0
... 14a9fb5f-5b0e-4862-b143-08a11cd3ebf0Substance use, including tobacco0..1group
.... CD-in-progress-29In progress0..1display
.... CD-complete-29Complete0..1display
.... CD-attention-29Attention required0..1display
.... substanceuse-smokingSmoking0..1group
..... substanceuse-smoking-smokingstatusSmoking status0..1group
...... substanceuse-smoking-smokingstatus-groupSmoking status0..1group
....... substanceuse-smoking-smokingstatus-group-laststatusLast status0..1display
....... substanceuse-smoking-smokingstatus-group-laststatusvaluenull0..1choiceiconiconValue Set: Tobacco Use Status
....... substanceuse-smoking-smokingstatus-group-laststatusdatenull0..1dateiconicon
....... b639a3a8-f476-4cc8-b5c7-f5d2abb23511New status0..1choiceValue Set: Tobacco Use Status
....... substanceuse-smoking-smokingstatus-group-newdateNew date0..1date
..... 96dc7c22-d003-459c-8a56-f6cd182fc077Quit status0..1choiceEnable When: b639a3a8-f476-4cc8-b5c7-f5d2abb23511 =
Value Set: Smoking Quit Status
..... 9e86387d-1be4-4c26-9047-9dd6b03e1ee0How many?0..1stringEnable When:
..... 32e71641-f660-4ca2-af99-dff8917f07beHow long as a smoker?0..1stringEnable When:
.... 34feaee8-8088-43ee-991d-9729990b5550Alcohol and other substance use0..1group
..... ea73d52c-f831-46be-a45d-2c42250a5210Quantity and frequency of: alcohol; caffeine (coffee, soft drinks, iced coffee); cannabis/yarndi/gunja; other substance use: IVDU, methamphetamine, opiates, solvents, other0..1text
.... f8e1cc1f-f1a1-4eb3-8255-77d600f52831Health priorities, actions and follow-up0..1text
.... substanceuse-section-end-dividernull0..1display
.... MarkComplete-29Section completion status0..1choiceOptions: 3 options

doco Documentation for this format

Options Sets

Answer options for MarkComplete-29

  • Complete
  • In progress
  • Attention required

Contained Resources


Observation #SmokingStatusTemplate

status: Final

category: Social History

code: Smoking status

subject: ?rref?

effective: Extract Template - Extract value: %resource.repeat(item).where(linkId='substanceuse-smoking-smokingstatus-group-newdate').answer.value.toDateTime()

value:


ValueSet #SmokingQuitStatus-1

This ValueSet requires the Code system Supplement SNOMED CT Supplement for Aboriginal and Torres Strait Islander Health Check.

This value set expansion contains 2 concepts.

SystemVersionCodeDisplay
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  48031000119106Quit >12 months
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  735128000Quit <12 months

ValueSet #TobaccoUseStatus-1

This ValueSet requires the Code system Supplement SNOMED CT Supplement for Aboriginal and Torres Strait Islander Health Check.

This value set expansion contains 6 concepts.

SystemVersionCodeDisplay
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  266919005Never smoked
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  77176002Current smoker
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  8517006Ex-smoker
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  16090371000119103Exposure to second hand tobacco smoke
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  394872000Wants to quit
http://snomed.info/scthttp://snomed.info/sct/32506021000036107/version/20251031  713914004Other tobacco use

Source1

{
  "resourceType": "Questionnaire",
  "id": "SubstanceUse",
  "meta": {
    "profile": [
      "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-render",
      "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-modular",
      "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-behave",
      "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-extr-template"
    ]
  },
  "text": {
    "status": "extensions",
    "div": "<!-- snip (see above) -->"
  },
  "contained": [
    {
      "resourceType": "Observation",
      "id": "SmokingStatusTemplate",
      "status": "final",
      "category": [
        {
          "coding": [
            {
              "system": "http://terminology.hl7.org/CodeSystem/observation-category",
              "code": "social-history"
            }
          ]
        }
      ],
      "code": {
        "coding": [
          {
            "system": "http://snomed.info/sct",
            "code": "1747861000168109"
          },
          {
            "system": "http://loinc.org",
            "code": "72166-2"
          }
        ],
        "text": "Smoking status"
      },
      "subject": {
        "_reference": {
          "extension": [
            {
              "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-templateExtractValue",
              "valueString": "%resource.subject.reference"
            }
          ]
        }
      },
      "_effectiveDateTime": {
        "extension": [
          {
            "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-templateExtractValue",
            "valueString": "%resource.repeat(item).where(linkId='substanceuse-smoking-smokingstatus-group-newdate').answer.value.toDateTime()"
          }
        ]
      },
      "valueCodeableConcept": {
        "coding": [
          {
            "extension": [
              {
                "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-templateExtractValue",
                "valueString": "$this.answer.value"
              }
            ]
          }
        ]
      }
    },
    {
      "resourceType": "ValueSet",
      "id": "SmokingQuitStatus-1",
      "extension": [
        {
          "url": "http://hl7.org/fhir/StructureDefinition/valueset-supplement",
          "valueCanonical": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
        }
      ],
      "url": "https://smartforms.csiro.au/ig/ValueSet/SmokingQuitStatus-1",
      "name": "SmokingQuitStatus",
      "title": "Smoking Quit Status",
      "status": "draft",
      "experimental": false,
      "description": "The Smoking Quit Status value set includes values that can indicate how long ago an individual quit smoking.",
      "compose": {
        "include": [
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "concept": [
              {
                "code": "48031000119106",
                "display": "Quit >12 months"
              },
              {
                "code": "735128000",
                "display": "Quit <12 months"
              }
            ]
          }
        ]
      },
      "expansion": {
        "identifier": "urn:uuid:ee67ad1e-7faa-4fe8-ab3e-1995de4fcd26",
        "timestamp": "2025-10-29T09:44:35+10:00",
        "parameter": [
          {
            "name": "used-codesystem",
            "valueUri": "http://snomed.info/sct|http://snomed.info/sct/32506021000036107/version/20251031"
          },
          {
            "name": "version",
            "valueUri": "http://snomed.info/sct|http://snomed.info/sct/32506021000036107/version/20251031"
          },
          {
            "name": "used-supplement",
            "valueUri": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
          },
          {
            "name": "warning-draft",
            "valueUri": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
          },
          {
            "name": "warning-draft",
            "valueUri": "https://smartforms.csiro.au/ig/ValueSet/SmokingQuitStatus-1|0.4.0"
          }
        ],
        "contains": [
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "48031000119106",
            "display": "Quit >12 months"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "735128000",
            "display": "Quit <12 months"
          }
        ]
      }
    },
    {
      "resourceType": "ValueSet",
      "id": "TobaccoUseStatus-1",
      "extension": [
        {
          "url": "http://hl7.org/fhir/StructureDefinition/valueset-supplement",
          "valueCanonical": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
        }
      ],
      "url": "https://smartforms.csiro.au/ig/ValueSet/TobaccoUseStatus-1",
      "name": "TobaccoUseStatus",
      "title": "Tobacco Use Status",
      "status": "draft",
      "experimental": false,
      "description": "The Tobacco Use Status value set includes values that may be used to represent an individual's current tobacco use and exposure status.",
      "compose": {
        "include": [
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "concept": [
              {
                "code": "266919005",
                "display": "Never smoked"
              },
              {
                "code": "77176002",
                "display": "Current smoker"
              },
              {
                "code": "8517006",
                "display": "Ex-smoker"
              },
              {
                "code": "16090371000119103",
                "display": "Exposure to second hand tobacco smoke"
              },
              {
                "code": "394872000",
                "display": "Wants to quit"
              },
              {
                "code": "713914004",
                "display": "Other tobacco use"
              }
            ]
          }
        ]
      },
      "expansion": {
        "identifier": "urn:uuid:a7d04dc0-077c-4744-8e21-da8ce4cba135",
        "timestamp": "2025-10-29T09:46:14+10:00",
        "parameter": [
          {
            "name": "used-codesystem",
            "valueUri": "http://snomed.info/sct|http://snomed.info/sct/32506021000036107/version/20251031"
          },
          {
            "name": "version",
            "valueUri": "http://snomed.info/sct|http://snomed.info/sct/32506021000036107/version/20251031"
          },
          {
            "name": "used-supplement",
            "valueUri": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
          },
          {
            "name": "warning-draft",
            "valueUri": "https://smartforms.csiro.au/ig/CodeSystem/HealthChecksSCTSupplement|0.4.0"
          },
          {
            "name": "warning-draft",
            "valueUri": "https://smartforms.csiro.au/ig/ValueSet/TobaccoUseStatus-1|0.4.0"
          }
        ],
        "contains": [
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "266919005",
            "display": "Never smoked"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "77176002",
            "display": "Current smoker"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "8517006",
            "display": "Ex-smoker"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "16090371000119103",
            "display": "Exposure to second hand tobacco smoke"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "394872000",
            "display": "Wants to quit"
          },
          {
            "system": "http://snomed.info/sct",
            "version": "http://snomed.info/sct/32506021000036107/version/20251031",
            "code": "713914004",
            "display": "Other tobacco use"
          }
        ]
      }
    }
  ],
  "extension": [
    {
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-assemble-expectation",
      "valueCode": "assemble-child"
    },
    {
      "extension": [
        {
          "url": "name",
          "valueCoding": {
            "system": "http://hl7.org/fhir/uv/sdc/CodeSystem/launchContext",
            "code": "patient"
          }
        },
        {
          "url": "type",
          "valueCode": "Patient"
        },
        {
          "url": "description",
          "valueString": "The patient that is to be used to pre-populate the form"
        }
      ],
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-launchContext"
    },
    {
      "extension": [
        {
          "url": "name",
          "valueCoding": {
            "system": "http://hl7.org/fhir/uv/sdc/CodeSystem/launchContext",
            "code": "user"
          }
        },
        {
          "url": "type",
          "valueCode": "Practitioner"
        },
        {
          "url": "description",
          "valueString": "The practitioner user that is to be used to pre-populate the form"
        }
      ],
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-launchContext"
    },
    {
      "extension": [
        {
          "url": "name",
          "valueCoding": {
            "system": "http://hl7.org/fhir/uv/sdc/CodeSystem/launchContext",
            "code": "encounter"
          }
        },
        {
          "url": "type",
          "valueCode": "Encounter"
        },
        {
          "url": "description",
          "valueString": "The encounter that is to be used to pre-populate the form"
        }
      ],
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-launchContext"
    },
    {
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-assembleContext",
      "valueString": "age"
    },
    {
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-assembleContext",
      "valueString": "ObsTobaccoSmokingStatus"
    },
    {
      "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-assembleContext",
      "valueString": "ObsTobaccoSmokingStatusLatest"
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/variable",
      "valueExpression": {
        "name": "ObsTobaccoSmokingStatusValue",
        "language": "text/fhirpath",
        "expression": "%ObsTobaccoSmokingStatusLatest.value.coding.where(system='http://snomed.info/sct').first()"
      }
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/variable",
      "valueExpression": {
        "name": "ObsTobaccoSmokingStatusDateString",
        "language": "text/fhirpath",
        "expression": "%ObsTobaccoSmokingStatusLatest.effective.toString().substring(0,10)"
      }
    },
    {
      "url": "http://hl7.org/fhir/StructureDefinition/variable",
      "valueExpression": {
        "name": "ObsTobaccoSmokingStatusDateFormatted",
        "language": "text/fhirpath",
        "expression": "%ObsTobaccoSmokingStatusDateString.substring(8,2).toInteger().toString() + ' ' + %ObsTobaccoSmokingStatusDateString.substring(5,2).replace('01','Jan').replace('02','Feb').replace('03','Mar').replace('04','Apr').replace('05','May').replace('06','Jun').replace('07','Jul').replace('08','Aug').replace('09','Sep').replace('10','Oct').replace('11','Nov').replace('12','Dec') + ' ' + %ObsTobaccoSmokingStatusDateString.substring(0,4)"
      }
    },
    {
      "url": "http://hl7.org/fhir/5.0/StructureDefinition/extension-Questionnaire.versionAlgorithm[x]",
      "valueCoding": {
        "system": "http://hl7.org/fhir/version-algorithm",
        "code": "semver"
      }
    }
  ],
  "url": "http://www.health.gov.au/assessments/mbs/715/SubstanceUse",
  "version": "0.4.0",
  "name": "SubstanceUse",
  "title": "Aboriginal and Torres Strait Islander Health Check - Substance Use",
  "status": "draft",
  "experimental": false,
  "subjectType": [
    "Patient"
  ],
  "date": "2025-03-14",
  "publisher": "AEHRC CSIRO",
  "contact": [
    {
      "name": "AEHRC CSIRO",
      "telecom": [
        {
          "system": "url",
          "value": "https://confluence.csiro.au/display/PCDQFPhase2/Primary+Care+Data+Quality+Foundations+-+Phase+2"
        }
      ]
    }
  ],
  "jurisdiction": [
    {
      "coding": [
        {
          "system": "urn:iso:std:iso:3166",
          "code": "AU",
          "display": "Australia"
        }
      ]
    }
  ],
  "copyright": "Copyright © 2022+ Australian Government Department of Health and Aged Care - All rights reserved.\nThis content is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.\nSee https://creativecommons.org/licenses/by-sa/4.0/.\n",
  "item": [
    {
      "extension": [
        {
          "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-enableWhenExpression",
          "valueExpression": {
            "language": "text/fhirpath",
            "expression": "%age >= 12"
          }
        }
      ],
      "linkId": "14a9fb5f-5b0e-4862-b143-08a11cd3ebf0",
      "text": "Substance use, including tobacco",
      "type": "group",
      "repeats": false,
      "item": [
        {
          "extension": [
            {
              "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-enableWhenExpression",
              "valueExpression": {
                "language": "text/fhirpath",
                "expression": "%resource.repeat(item).where(linkId='MarkComplete-29').answer.value = 'In progress' or %resource.repeat(item).where(linkId='MarkComplete-29').answer.value.empty()"
              }
            },
            {
              "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
              "valueCodeableConcept": {
                "coding": [
                  {
                    "system": "https://smartforms.csiro.au/ig/CodeSystem/QuestionnaireItemControlExtended",
                    "code": "context-display"
                  }
                ]
              }
            }
          ],
          "linkId": "CD-in-progress-29",
          "text": "In progress",
          "_text": {
            "extension": [
              {
                "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                "valueString": "<div title=\"In progress\" xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">\r\n\t\t<img width='24' height='24' src='data:image/svg+xml;base64,\r\n\t\tPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IiM3NTc1NzUiIGQ9Im0xNS44NCAxMC4ybC0xLjAxIDEuMDFsLTIuMDctMi4wM2wxLjAxLTEuMDJjLjItLjIxLjU0LS4yMi43OCAwbDEuMjkgMS4yNWMuMjEuMjEuMjIuNTUgMCAuNzlNOCAxMy45MWw0LjE3LTQuMTlsMi4wNyAyLjA4bC00LjE2IDQuMkg4di0yLjA5TTEzIDJ2MmM0LjM5LjU0IDcuNSA0LjUzIDYuOTYgOC45MkE4LjAxNCA4LjAxNCAwIDAgMSAxMyAxOS44OHYyYzUuNS0uNiA5LjQ1LTUuNTQgOC44NS0xMS4wM0MyMS4zMyA2LjE5IDE3LjY2IDIuNSAxMyAybS0yIDBjLTEuOTYuMTgtMy44MS45NS01LjMzIDIuMkw3LjEgNS43NGMxLjEyLS45IDIuNDctMS40OCAzLjktMS42OHYtMk00LjI2IDUuNjdBOS44MSA5LjgxIDAgMCAwIDIuMDUgMTFoMmMuMTktMS40Mi43NS0yLjc3IDEuNjQtMy45TDQuMjYgNS42N00yLjA2IDEzYy4yIDEuOTYuOTcgMy44MSAyLjIxIDUuMzNsMS40Mi0xLjQzQTguMDAyIDguMDAyIDAgMCAxIDQuMDYgMTNoLTJtNSA1LjM3bC0xLjM5IDEuMzdBOS45OTQgOS45OTQgMCAwIDAgMTEgMjJ2LTJhOC4wMDIgOC4wMDIgMCAwIDEtMy45LTEuNjNoLS4wNFoiLz48L3N2Zz4=' \r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
              }
            ]
          },
          "type": "display"
        },
        {
          "extension": [
            {
              "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-enableWhenExpression",
              "valueExpression": {
                "language": "text/fhirpath",
                "expression": "%resource.repeat(item).where(linkId='MarkComplete-29').answer.value = 'Complete'"
              }
            },
            {
              "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
              "valueCodeableConcept": {
                "coding": [
                  {
                    "system": "https://smartforms.csiro.au/ig/CodeSystem/QuestionnaireItemControlExtended",
                    "code": "context-display"
                  }
                ]
              }
            }
          ],
          "linkId": "CD-complete-29",
          "text": "Complete",
          "_text": {
            "extension": [
              {
                "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                "valueString": "<div title=\"Complete\" xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">\r\n\t\t<img width='24' height='24' src='data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IiMyZTdkMzIiIGQ9Ik0yMCAxMmE4IDggMCAwIDEtOCA4YTggOCAwIDAgMS04LThhOCA4IDAgMCAxIDgtOGMuNzYgMCAxLjUuMTEgMi4yLjMxbDEuNTctMS41N0E5LjgyMiA5LjgyMiAwIDAgMCAxMiAyQTEwIDEwIDAgMCAwIDIgMTJhMTAgMTAgMCAwIDAgMTAgMTBhMTAgMTAgMCAwIDAgMTAtMTBNNy45MSAxMC4wOEw2LjUgMTEuNUwxMSAxNkwyMSA2bC0xLjQxLTEuNDJMMTEgMTMuMTdsLTMuMDktMy4wOVoiLz48L3N2Zz4='\r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
              }
            ]
          },
          "type": "display"
        },
        {
          "extension": [
            {
              "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-enableWhenExpression",
              "valueExpression": {
                "language": "text/fhirpath",
                "expression": "%resource.repeat(item).where(linkId='MarkComplete-29').answer.value = 'Attention required'"
              }
            },
            {
              "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
              "valueCodeableConcept": {
                "coding": [
                  {
                    "system": "https://smartforms.csiro.au/ig/CodeSystem/QuestionnaireItemControlExtended",
                    "code": "context-display"
                  }
                ]
              }
            }
          ],
          "linkId": "CD-attention-29",
          "text": "Attention required",
          "_text": {
            "extension": [
              {
                "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                "valueString": "<div title=\"Attention required\" xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">\r\n\t\t<img width='24' height='24' src='data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDAgMTAwIj48Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSI0MiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjRkY4QzAwIiBzdHJva2Utd2lkdGg9IjkiLz48bGluZSB4MT0iNTAiIHkxPSIyOCIgeDI9IjUwIiB5Mj0iNjAiIHN0cm9rZT0iI0ZGOEMwMCIgc3Ryb2tlLXdpZHRoPSI5Ii8+PGNpcmNsZSBjeD0iNTAiIGN5PSI3NCIgcj0iNSIgZmlsbD0iI0ZGOEMwMCIvPjwvc3ZnPg=='\r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
              }
            ]
          },
          "type": "display"
        },
        {
          "linkId": "substanceuse-smoking",
          "text": "Smoking",
          "type": "group",
          "repeats": false,
          "item": [
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
                  "valueCodeableConcept": {
                    "coding": [
                      {
                        "system": "http://hl7.org/fhir/questionnaire-item-control",
                        "code": "grid"
                      }
                    ]
                  }
                }
              ],
              "linkId": "substanceuse-smoking-smokingstatus",
              "text": "Smoking status",
              "_text": {
                "extension": [
                  {
                    "url": "https://smartforms.csiro.au/ig/StructureDefinition/QuestionnaireItemTextHidden",
                    "valueBoolean": true
                  }
                ]
              },
              "type": "group",
              "repeats": false,
              "item": [
                {
                  "linkId": "substanceuse-smoking-smokingstatus-group",
                  "text": "Smoking status",
                  "type": "group",
                  "repeats": false,
                  "item": [
                    {
                      "linkId": "substanceuse-smoking-smokingstatus-group-laststatus",
                      "text": "Last status",
                      "_text": {
                        "extension": [
                          {
                            "url": "http://hl7.org/fhir/StructureDefinition/cqf-expression",
                            "valueExpression": {
                              "language": "text/fhirpath",
                              "expression": "iif(%ObsTobaccoSmokingStatusValue.exists() and %ObsTobaccoSmokingStatusDateFormatted.exists(), %ObsTobaccoSmokingStatusValue.display + ' ( ' + %ObsTobaccoSmokingStatusDateFormatted + ' )', 'Not available')"
                            }
                          }
                        ]
                      },
                      "type": "display"
                    },
                    {
                      "extension": [
                        {
                          "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-initialExpression",
                          "valueExpression": {
                            "language": "text/fhirpath",
                            "expression": "%ObsTobaccoSmokingStatusValue"
                          }
                        },
                        {
                          "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-hidden",
                          "valueBoolean": true
                        },
                        {
                          "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "system": "http://hl7.org/fhir/questionnaire-item-control",
                                "code": "drop-down"
                              }
                            ]
                          }
                        }
                      ],
                      "linkId": "substanceuse-smoking-smokingstatus-group-laststatusvalue",
                      "type": "choice",
                      "repeats": false,
                      "answerValueSet": "#TobaccoUseStatus-1"
                    },
                    {
                      "extension": [
                        {
                          "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-initialExpression",
                          "valueExpression": {
                            "language": "text/fhirpath",
                            "expression": "%ObsTobaccoSmokingStatusLatest.effective.toString().substring(0,10).toDate()"
                          }
                        },
                        {
                          "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-hidden",
                          "valueBoolean": true
                        }
                      ],
                      "linkId": "substanceuse-smoking-smokingstatus-group-laststatusdate",
                      "type": "date",
                      "repeats": false
                    },
                    {
                      "extension": [
                        {
                          "extension": [
                            {
                              "url": "template",
                              "valueReference": {
                                "reference": "#SmokingStatusTemplate"
                              }
                            }
                          ],
                          "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-templateExtract"
                        },
                        {
                          "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
                          "valueCodeableConcept": {
                            "coding": [
                              {
                                "system": "http://hl7.org/fhir/questionnaire-item-control",
                                "code": "drop-down"
                              }
                            ]
                          }
                        }
                      ],
                      "linkId": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                      "text": "New status",
                      "type": "choice",
                      "repeats": false,
                      "answerValueSet": "#TobaccoUseStatus-1"
                    },
                    {
                      "linkId": "substanceuse-smoking-smokingstatus-group-newdate",
                      "text": "New date",
                      "type": "date",
                      "repeats": false
                    }
                  ]
                }
              ]
            },
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
                  "valueCodeableConcept": {
                    "coding": [
                      {
                        "system": "http://hl7.org/fhir/questionnaire-item-control",
                        "code": "radio-button"
                      }
                    ]
                  }
                }
              ],
              "linkId": "96dc7c22-d003-459c-8a56-f6cd182fc077",
              "text": "Quit status",
              "type": "choice",
              "enableWhen": [
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "8517006"
                  }
                }
              ],
              "repeats": false,
              "answerValueSet": "#SmokingQuitStatus-1"
            },
            {
              "linkId": "9e86387d-1be4-4c26-9047-9dd6b03e1ee0",
              "text": "How many?",
              "type": "string",
              "enableWhen": [
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "77176002"
                  }
                },
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "8517006"
                  }
                },
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "394872000"
                  }
                }
              ],
              "enableBehavior": "any",
              "repeats": false
            },
            {
              "linkId": "32e71641-f660-4ca2-af99-dff8917f07be",
              "text": "How long as a smoker?",
              "type": "string",
              "enableWhen": [
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "77176002"
                  }
                },
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "8517006"
                  }
                },
                {
                  "question": "b639a3a8-f476-4cc8-b5c7-f5d2abb23511",
                  "operator": "=",
                  "answerCoding": {
                    "system": "http://snomed.info/sct",
                    "code": "394872000"
                  }
                }
              ],
              "enableBehavior": "any"
            }
          ]
        },
        {
          "linkId": "34feaee8-8088-43ee-991d-9729990b5550",
          "text": "Alcohol and other substance use",
          "type": "group",
          "repeats": false,
          "item": [
            {
              "extension": [
                {
                  "url": "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-shortText",
                  "valueString": "Quantity and frequency of substance use"
                },
                {
                  "url": "http://hl7.org/fhir/StructureDefinition/entryFormat",
                  "valueString": "Details"
                }
              ],
              "linkId": "ea73d52c-f831-46be-a45d-2c42250a5210",
              "text": "Quantity and frequency of: alcohol; caffeine (coffee, soft drinks, iced coffee); cannabis/yarndi/gunja; other substance use: IVDU, methamphetamine, opiates, solvents, other",
              "_text": {
                "extension": [
                  {
                    "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                    "valueString": "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n        <div>Quantity and frequency of:</div>\n        <ul>\n          <li>alcohol</li>\n          <li>caffeine (coffee, soft drinks, iced coffee)</li>\n          <li>cannabis/yarndi/gunja</li>\n          <li>other substance use: IVDU, methamphetamine, opiates, solvents, other</li>\n        </ul>\n\t      </div>"
                  }
                ]
              },
              "type": "text",
              "repeats": false
            }
          ]
        },
        {
          "linkId": "f8e1cc1f-f1a1-4eb3-8255-77d600f52831",
          "text": "Health priorities, actions and follow-up",
          "type": "text",
          "repeats": false
        },
        {
          "linkId": "substanceuse-section-end-divider",
          "_text": {
            "extension": [
              {
                "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                "valueString": "<div xmlns=\"http://www.w3.org/1999/xhtml\" style=\"border-top: 1px solid #ccc;\"></div>"
              }
            ]
          },
          "type": "display"
        },
        {
          "extension": [
            {
              "url": "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl",
              "valueCodeableConcept": {
                "coding": [
                  {
                    "system": "http://hl7.org/fhir/questionnaire-item-control",
                    "code": "radio-button"
                  }
                ]
              }
            }
          ],
          "linkId": "MarkComplete-29",
          "text": "Section completion status",
          "type": "choice",
          "repeats": false,
          "answerOption": [
            {
              "valueString": "Complete",
              "_valueString": {
                "extension": [
                  {
                    "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                    "valueString": "<div xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">Complete&nbsp;\r\n\t\t<img width='19' height='19' src='data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IiMyZTdkMzIiIGQ9Ik0yMCAxMmE4IDggMCAwIDEtOCA4YTggOCAwIDAgMS04LThhOCA4IDAgMCAxIDgtOGMuNzYgMCAxLjUuMTEgMi4yLjMxbDEuNTctMS41N0E5LjgyMiA5LjgyMiAwIDAgMCAxMiAyQTEwIDEwIDAgMCAwIDIgMTJhMTAgMTAgMCAwIDAgMTAgMTBhMTAgMTAgMCAwIDAgMTAtMTBNNy45MSAxMC4wOEw2LjUgMTEuNUwxMSAxNkwyMSA2bC0xLjQxLTEuNDJMMTEgMTMuMTdsLTMuMDktMy4wOVoiLz48L3N2Zz4='\r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
                  }
                ]
              }
            },
            {
              "valueString": "In progress",
              "_valueString": {
                "extension": [
                  {
                    "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                    "valueString": "<div xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">In progress&nbsp;\r\n\t\t<img width='20' height='20' src='data:image/svg+xml;base64,\r\n\t\tPHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IiM3NTc1NzUiIGQ9Im0xNS44NCAxMC4ybC0xLjAxIDEuMDFsLTIuMDctMi4wM2wxLjAxLTEuMDJjLjItLjIxLjU0LS4yMi43OCAwbDEuMjkgMS4yNWMuMjEuMjEuMjIuNTUgMCAuNzlNOCAxMy45MWw0LjE3LTQuMTlsMi4wNyAyLjA4bC00LjE2IDQuMkg4di0yLjA5TTEzIDJ2MmM0LjM5LjU0IDcuNSA0LjUzIDYuOTYgOC45MkE4LjAxNCA4LjAxNCAwIDAgMSAxMyAxOS44OHYyYzUuNS0uNiA5LjQ1LTUuNTQgOC44NS0xMS4wM0MyMS4zMyA2LjE5IDE3LjY2IDIuNSAxMyAybS0yIDBjLTEuOTYuMTgtMy44MS45NS01LjMzIDIuMkw3LjEgNS43NGMxLjEyLS45IDIuNDctMS40OCAzLjktMS42OHYtMk00LjI2IDUuNjdBOS44MSA5LjgxIDAgMCAwIDIuMDUgMTFoMmMuMTktMS40Mi43NS0yLjc3IDEuNjQtMy45TDQuMjYgNS42N00yLjA2IDEzYy4yIDEuOTYuOTcgMy44MSAyLjIxIDUuMzNsMS40Mi0xLjQzQTguMDAyIDguMDAyIDAgMCAxIDQuMDYgMTNoLTJtNSA1LjM3bC0xLjM5IDEuMzdBOS45OTQgOS45OTQgMCAwIDAgMTEgMjJ2LTJhOC4wMDIgOC4wMDIgMCAwIDEtMy45LTEuNjNoLS4wNFoiLz48L3N2Zz4=' \r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
                  }
                ]
              }
            },
            {
              "valueString": "Attention required",
              "_valueString": {
                "extension": [
                  {
                    "url": "http://hl7.org/fhir/StructureDefinition/rendering-xhtml",
                    "valueString": "<div xmlns=\"http://www.w3.org/1999/xhtml\">\r\n\t<div style=\"display: flex; flex-direction: row;\">Attention required&nbsp;\r\n\t\t<img width='19' height='19' src='data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDAgMTAwIj48Y2lyY2xlIGN4PSI1MCIgY3k9IjUwIiByPSI0MiIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjRkY4QzAwIiBzdHJva2Utd2lkdGg9IjkiLz48bGluZSB4MT0iNTAiIHkxPSIyOCIgeDI9IjUwIiB5Mj0iNjAiIHN0cm9rZT0iI0ZGOEMwMCIgc3Ryb2tlLXdpZHRoPSI5Ii8+PGNpcmNsZSBjeD0iNTAiIGN5PSI3NCIgcj0iNSIgZmlsbD0iI0ZGOEMwMCIvPjwvc3ZnPg=='\r\n\t\tstyle=\"align-self: center;\"/>\r\n\t</div>\r\n</div>"
                  }
                ]
              }
            }
          ]
        }
      ]
    }
  ]
}