{% capture childItems %}{% if QuestionnaireResponse.item.where(linkId = 'patient_header').exists() %}Patient Information {% for currentItem in QuestionnaireResponse.item.where(linkId = 'patient_header') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'patient_surname' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_surname' and answer.exists()) %}{% if currentItem.answer.exists() %}Surname: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_firstname' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_firstname' and answer.exists()) %}{% if currentItem.answer.exists() %}First Name: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_date_of_birth' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_date_of_birth' and answer.exists()) %}{% if currentItem.answer.exists() %}DOB: {% for answer in currentItem.answer %}{{ answer.value.ofType(date) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_gender' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_gender' and answer.exists()) %}{% if currentItem.answer.exists() %}Gender: {% for answer in currentItem.answer %}{% if answer.value.code = 'male' %}Male{% endif %}{% if answer.value.code = 'female' %}Female{% endif %}{% if answer.value.code = 'other' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_hc_pc' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_hc_pc' and answer.exists()) %}{% if currentItem.answer.exists() %}HN PC: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_hc_number' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_hc_number' and answer.exists()) %}{% if currentItem.answer.exists() %}HN: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_hc_vc' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_hc_vc' and answer.exists()) %}{% if currentItem.answer.exists() %}HN VC: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_address_line1' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_address_line1' and answer.exists()) %}{% if currentItem.answer.exists() %}Address (Line 1): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_address_line2' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_address_line2' and answer.exists()) %}{% if currentItem.answer.exists() %}Address (Line 2): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_address_city' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_address_city' and answer.exists()) %}{% if currentItem.answer.exists() %}City: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_address_province' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_address_province' and answer.exists()) %}{% if currentItem.answer.exists() %}Province: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_address_postalcode' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_address_postalcode' and answer.exists()) %}{% if currentItem.answer.exists() %}Postal Code: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_phone_mobile' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_phone_mobile' and answer.exists()) %}{% if currentItem.answer.exists() %}Mobile #: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_phone_home' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_phone_home' and answer.exists()) %}{% if currentItem.answer.exists() %}Home #: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_phone_business' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_phone_business' and answer.exists()) %}{% if currentItem.answer.exists() %}Business #: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'patient_email' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'patient_email' and answer.exists()) %}{% if currentItem.answer.exists() %}Email: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'additionalinfo_header').exists() %}[Optional] Additional Patient Information {% for currentItem in QuestionnaireResponse.item.where(linkId = 'additionalinfo_header') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_preferredname' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_preferredname' and answer.exists()) %}{% if currentItem.answer.exists() %}Preferred Name {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_sexassignedatbirth' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_sexassignedatbirth' and answer.exists()) %}{% if currentItem.answer.exists() %}Sex assigned at birth: {% for answer in currentItem.answer %}{% if answer.value = 'Female' %}Female{% endif %}{% if answer.value = 'Male' %}Male{% endif %}{% if answer.value = 'Intersex' %}Intersex{% endif %}{% if answer.value = 'Unknown' %}Unknown{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_pronouns' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_pronouns' and answer.exists()) %}{% if currentItem.answer.exists() %}Pronouns: {% for answer in currentItem.answer %}{% if answer.value.code = '21317' %}She/Her{% endif %}{% if answer.value.code = '21318' %}He/Him{% endif %}{% if answer.value.code = '21319' %}They/Them{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_pronouns_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_pronouns_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other pronouns: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_preferredlanguage' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_preferredlanguage' and answer.exists()) %}{% if currentItem.answer.exists() %}Preferred language {% for answer in currentItem.answer %}{% if answer.value.code = 'en' %}English{% endif %}{% if answer.value.code = 'fr' %}French{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_section').exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_section') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify language and considerations: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_interpreterrequired' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_preferredlanguage_interpreterrequired' and answer.exists()) %}{% if currentItem.answer.exists() %}Interpreter Required {% for answer in currentItem.answer %}{% if answer.value = 'Interpreter Required' %}Interpreter Required{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact' and answer.exists()) %}{% if currentItem.answer.exists() %}Best method of contact: {% for answer in currentItem.answer %}{% if answer.value.code = 'mobile' %}Mobile{% endif %}{% if answer.value.code = 'home' %}Home{% endif %}{% if answer.value.code = 'work' %}Work{% endif %}{% if answer.value.code = 'email' %}Email{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact_voicemails' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact_voicemails' and answer.exists()) %}{% if currentItem.answer.exists() %}Voicemails acceptable {% for answer in currentItem.answer %}{% if answer.value = 'Voicemails acceptable' %}Voicemails acceptable{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact_prefersms' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_bestmethodofcontact_prefersms' and answer.exists()) %}{% if currentItem.answer.exists() %}Patient prefers SMS/text if available {% for answer in currentItem.answer %}{% if answer.value = 'Prefer SMS/Text if available' %}Prefer SMS/Text if available{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM' and answer.exists()) %}{% if currentItem.answer.exists() %}Identify parent/guardian, care contact, or Substitute Decision Maker (SDM) {% for answer in currentItem.answer %}{% if answer.value = 'Identify parent/guardian, care contact, or Substitute Decision Maker' %}Identify parent/guardian, care contact, or Substitute Decision Maker{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_section').exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_section') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_name' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_name' and answer.exists()) %}{% if currentItem.answer.exists() %}First Contact name: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_phone' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_phone' and answer.exists()) %}{% if currentItem.answer.exists() %}Phone (if different than pt): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_email' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_email' and answer.exists()) %}{% if currentItem.answer.exists() %}Email (if different than pt): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_relation' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_relation' and answer.exists()) %}{% if currentItem.answer.exists() %}Relationship (incl. SDM): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_apptbookcontact' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_firstcontact_apptbookcontact' and answer.exists()) %}{% if currentItem.answer.exists() %}Is this person an appointment booking contact? {% for answer in currentItem.answer %}{% if answer.value = 'Yes' %}Yes{% endif %}{% if answer.value = 'No' %}No{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_name' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_name' and answer.exists()) %}{% if currentItem.answer.exists() %}Second Contact name: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_phone' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_phone' and answer.exists()) %}{% if currentItem.answer.exists() %}Phone (if different than pt): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_email' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_email' and answer.exists()) %}{% if currentItem.answer.exists() %}Email (if different than pt): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_relation' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_relation' and answer.exists()) %}{% if currentItem.answer.exists() %}Relationship (incl. SDM): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_apptbookcontact' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_parentguardianSDM_secondcontact_apptbookcontact' and answer.exists()) %}{% if currentItem.answer.exists() %}Is this person an appointment booking contact? {% for answer in currentItem.answer %}{% if answer.value = 'Yes' %}Yes{% endif %}{% if answer.value = 'No' %}No{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_unsafecontactsprivacy_select' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_unsafecontactsprivacy_select' and answer.exists()) %}{% if currentItem.answer.exists() %}Do not contact (e.g. safety, privacy) {% for answer in currentItem.answer %}{% if answer.value = 'Do not contact (e.g. safety, privacy)' %}Do not contact (e.g. safety, privacy){% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_unsafecontactsprivacy_section').exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_unsafecontactsprivacy_section') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_unsafecontacts_speakwithpatientdirectly' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_unsafecontacts_speakwithpatientdirectly' and answer.exists()) %}{% if currentItem.answer.exists() %}Only contact patient directly {% for answer in currentItem.answer %}{% if answer.value = 'Only contact patient directly' %}Only contact patient directly{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_unsafecontacts_donotspeakwith' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_unsafecontacts_donotspeakwith' and answer.exists()) %}{% if currentItem.answer.exists() %}Do not speak with: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_select' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_select' and answer.exists()) %}{% if currentItem.answer.exists() %}Accessibility concerns or disability {% for answer in currentItem.answer %}{% if answer.value = 'Accessibility concerns or disability' %}Accessibility concerns or disability{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_section').exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_section') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '21269' %}Cognitively impaired{% endif %}{% if answer.value.code = '21270' %}Falls risk{% endif %}{% if answer.value.code = '21271' %}Hearing impaired{% endif %}{% if answer.value.code = '21272' %}Patient requires lift{% endif %}{% if answer.value.code = '21273' %}Vision impaired{% endif %}{% if answer.value.code = '21274' %}Wheelchair{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_accessibilityconcernsordisability_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_specialconsiderations_select' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_specialconsiderations_select' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value = 'Special considerations (e.g. barriers, tips for care delivery, 3rd party insurance, requires escort, current location)' %}Special considerations (e.g. barriers, tips for care delivery, 3rd party insurance, requires escort, current location){% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_specialconsiderations_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_specialconsiderations_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_specialconsiderations' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_specialconsiderations' and answer.exists()) %}{% if currentItem.answer.exists() %}Details of special considerations: {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value = 'Send copies of reports to additional providers' %}Send copies of reports to additional providers{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_group').exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_names' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_names' and answer.exists()) %}{% if currentItem.answer.exists() %}Name(s): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_contactinfo' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_contactinfo' and answer.exists()) %}{% if currentItem.answer.exists() %}Contact information: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_ispcp' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'additionalinfo_sendcopiestoadditionalproviders_ispcp' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value = 'This is the Primary Care Provider' %}This is the Primary Care Provider{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_payerType' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_payerType' and answer.exists()) %}{% if currentItem.answer.exists() %}Payer Type {% for answer in currentItem.answer %}{% if answer.value = 'OHIP' %}OHIP{% endif %}{% if answer.value = 'WSIB Case' %}WSIB Case{% endif %}{% if answer.value = 'DND' %}DND{% endif %}{% if answer.value = 'IFH' %}IFH{% endif %}{% if answer.value = 'RAMQ' %}RAMQ{% endif %}{% if answer.value = 'Other' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_payerType_other' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_payerType_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = '847648250958' and repeat(item).answer.exists()).exists() %}Exam(s) Requested {% for currentItem in QuestionnaireResponse.item.where(linkId = '847648250958' and repeat(item).answer.exists()) %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '20390' %}CT Requisition{% endif %}{% if answer.value.code = '20391' %}MRI Requisition{% endif %}{% if answer.value.code = '20392' %}X-Ray Requisition{% endif %}{% if answer.value.code = '20393' %}Ultrasound Requisition{% endif %}{% if answer.value.code = '20394' %}Bone Mineral Density Requisition{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_referral_triageconsiderations').exists() %}Triage Considerations {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_referral_triageconsiderations') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_triage' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_triage' and answer.exists()) %}{% if currentItem.answer.exists() %}Requested Triage Priority {% for answer in currentItem.answer %}{% if answer.value = 'Routine' %}Routine{% endif %}{% if answer.value = 'Urgent' %}Urgent{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_triage_urgentReason' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_triage_urgentReason' and answer.exists()) %}{% if currentItem.answer.exists() %}Reason for urgent triage: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_CT_group').exists() %}CT Exam/Region(s) of Interest: {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_CT_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head' and answer.exists()) %}{% if currentItem.answer.exists() %}Head {% for answer in currentItem.answer %}{% if answer.value.code = '20395' %}Head{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20406' %}Brain{% endif %}{% if answer.value.code = '20408' %}Facial bones{% endif %}{% if answer.value.code = '20447' %}Head angiography{% endif %}{% if answer.value.code = '20456' %}Head venography{% endif %}{% if answer.value.code = '20409' %}Internal auditory canals{% endif %}{% if answer.value.code = '20410' %}Orbits{% endif %}{% if answer.value.code = '20411' %}Sinuses{% endif %}{% if answer.value.code = '20412' %}Temporal bones{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_head_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck' and answer.exists()) %}{% if currentItem.answer.exists() %}Neck {% for answer in currentItem.answer %}{% if answer.value.code = '20396' %}Neck{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20448' %}Neck angiography{% endif %}{% if answer.value.code = '20414' %}Soft Tissue Neck{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_neck_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine' and answer.exists()) %}{% if currentItem.answer.exists() %}Spine {% for answer in currentItem.answer %}{% if answer.value.code = '20397' %}Spine{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_spine_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20415' %}Cervical Spine{% endif %}{% if answer.value.code = '20416' %}Thoracic Spine{% endif %}{% if answer.value.code = '20417' %}Lumbar Spine{% endif %}{% if answer.value.code = '20418' %}Sacrum/Coccyx{% endif %}{% if answer.value.code = '20419' %}Sacroiliac Joints{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax' and answer.exists()) %}{% if currentItem.answer.exists() %}Thorax {% for answer in currentItem.answer %}{% if answer.value.code = '20398' %}Thorax{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20420' %}Chest{% endif %}{% if answer.value.code = '20421' %}Chest High Resolution{% endif %}{% if answer.value.code = '20422' %}Chest Low-Dose{% endif %}{% if answer.value.code = '20449' %}Chest Angiography{% endif %}{% if answer.value.code = '20423' %}Pulmonary Embolism{% endif %}{% if answer.value.code = '20425' %}Thoracic Outlet{% endif %}{% if answer.value.code = '20426' %}Chest Abdomen Pelvis{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_thorax_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis' and answer.exists()) %}{% if currentItem.answer.exists() %}Abdomen Pelvis {% for answer in currentItem.answer %}{% if answer.value.code = '20399' %}Abdomen Pelvis{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20399' %}Abdomen Pelvis{% endif %}{% if answer.value.code = '20452' %}Abdomen Pelvis Angiography{% endif %}{% if answer.value.code = '20426' %}Chest Abdomen Pelvis{% endif %}{% if answer.value.code = '20427' %}Abdomen only{% endif %}{% if answer.value.code = '20428' %}Pelvis only{% endif %}{% if answer.value.code = '20430' %}Colonography{% endif %}{% if answer.value.code = '20431' %}Enterography{% endif %}{% if answer.value.code = '20432' %}Renal Colic{% endif %}{% if answer.value.code = '20433' %}Urography{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_abdomenpelvis_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal' and answer.exists()) %}{% if currentItem.answer.exists() %}Musculoskeletal {% for answer in currentItem.answer %}{% if answer.value.code = '20400' %}Musculoskeletal{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_musculoskeletal_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_musculoskeletal_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}"{% if answer.value.code = '20434' %}Shoulder{% endif %}{% if answer.value.code = '20435' %}Humerus{% endif %}{% if answer.value.code = '20436' %}Elbow{% endif %}{% if answer.value.code = '20437' %}Forearm{% endif %}{% if answer.value.code = '20438' %}Wrist{% endif %}{% if answer.value.code = '20439' %}Hand{% endif %}{% if answer.value.code = '20440' %}Bony Pelvis{% endif %}{% if answer.value.code = '20441' %}Hip{% endif %}{% if answer.value.code = '20442' %}Femur{% endif %}{% if answer.value.code = '20443' %}Knee{% endif %}{% if answer.value.code = '20444' %}Tibia and Fibula{% endif %}{% if answer.value.code = '20445' %}Ankle{% endif %}{% if answer.value.code = '20446' %}Foot{% endif %}"{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_shoulder' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_shoulder' and answer.exists()) %}{% if currentItem.answer.exists() %}Shoulder: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_humerus' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_humerus' and answer.exists()) %}{% if currentItem.answer.exists() %}Humerus: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_elbow' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_elbow' and answer.exists()) %}{% if currentItem.answer.exists() %}Elbow: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_forearm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_forearm' and answer.exists()) %}{% if currentItem.answer.exists() %}Forearm: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_wrist' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_wrist' and answer.exists()) %}{% if currentItem.answer.exists() %}Wrist: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_hand' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_hand' and answer.exists()) %}{% if currentItem.answer.exists() %}Hand: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_hip' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_hip' and answer.exists()) %}{% if currentItem.answer.exists() %}Hip: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_femur' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_femur' and answer.exists()) %}{% if currentItem.answer.exists() %}Femur: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_knee' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_knee' and answer.exists()) %}{% if currentItem.answer.exists() %}Knee: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_tibia' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_tibia' and answer.exists()) %}{% if currentItem.answer.exists() %}Tibia and Fibula: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_ankle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_ankle' and answer.exists()) %}{% if currentItem.answer.exists() %}Ankle: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_foot' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_musculoskeletal_foot' and answer.exists()) %}{% if currentItem.answer.exists() %}Foot: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial' and answer.exists()) %}{% if currentItem.answer.exists() %}CT Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '20401' %}Angiography{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_angiographyarterial_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_angiographyarterial_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20447' %}Head Angiography{% endif %}{% if answer.value.code = '20448' %}Neck Angiography{% endif %}{% if answer.value.code = '20449' %}Chest Angiography{% endif %}{% if answer.value.code = '20450' %}Chest Abdomen Pelvis Angiography{% endif %}{% if answer.value.code = '20451' %}Abdomen Angiography{% endif %}{% if answer.value.code = '20452' %}Abdomen Pelvis Angiography{% endif %}{% if answer.value.code = '20453' %}Pelvis Angiography{% endif %}{% if answer.value.code = '20454' %}Upper Extremity Angiography{% endif %}{% if answer.value.code = '20455' %}Lower Extremity Angiography{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_upper_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_upper_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Upper Extremity Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_lower_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_angiographyarterial_specificarea_lower_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Lower Extremity Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_myeloma' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_myeloma' and answer.exists()) %}{% if currentItem.answer.exists() %}Whole-Body Low-Dose (Myeloma) {% for answer in currentItem.answer %}{% if answer.value.code = '20403' %}Whole-Body Low-Dose (Myeloma){% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_cardiac' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_cardiac' and answer.exists()) %}{% if currentItem.answer.exists() %}Cardiac {% for answer in currentItem.answer %}{% if answer.value.code = '20404' %}Cardiac{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_cardiac_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_cardiac_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_cardiac_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_cardiac_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20465' %}Coronary Angiography (CCTA){% endif %}{% if answer.value.code = '20466' %}Cardiac Calcium Score{% endif %}{% if answer.value.code = '20464' %}Cardiac CT{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_biopsy' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_biopsy' and answer.exists()) %}{% if currentItem.answer.exists() %}Biopsy {% for answer in currentItem.answer %}{% if answer.value.code = '20405' %}Biopsy{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_biopsy_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_biopsy_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_biopsy_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_biopsy_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '21366' %}Adrenals{% endif %}{% if answer.value.code = '21367' %}Bone{% endif %}{% if answer.value.code = '21368' %}Kidneys{% endif %}{% if answer.value.code = '21369' %}Liver{% endif %}{% if answer.value.code = '21370' %}Lung{% endif %}{% if answer.value.code = '21371' %}Lymph nodes{% endif %}{% if answer.value.code = '21372' %}Mediastinal mass{% endif %}{% if answer.value.code = '21373' %}Pancreas{% endif %}{% if answer.value.code = '21374' %}Pelvis{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other {% for answer in currentItem.answer %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_other_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_CT_other_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %},{% else %},{% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_CT_clinicalindication_CTrefnote').exists() %}CT Request: Clinical History / Indication {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_CT_clinicalindication_CTrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_CT_clinicalindication_text' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_CT_clinicalindication_text' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_MRI_group_MRIrefnote').exists() %}MRI Exam/Region(s) of Interest: {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_MRI_group_MRIrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head' and answer.exists()) %}{% if currentItem.answer.exists() %}Head {% for answer in currentItem.answer %}{% if answer.value.code = '20467' %}Head{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20478' %}Brain{% endif %}{% if answer.value.code = '20540' %}Head angiography{% endif %}{% if answer.value.code = '20480' %}Internal auditory canals{% endif %}{% if answer.value.code = '20481' %}Orbits{% endif %}{% if answer.value.code = '20482' %}Pituitary / Sella{% endif %}{% if answer.value.code = '20483' %}Sinuses{% endif %}{% if answer.value.code = '20484' %}Temporomandibular joints{% endif %}{% if answer.value.code = '20485' %}Trigeminal nerve{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_head_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck' and answer.exists()) %}{% if currentItem.answer.exists() %}Neck {% for answer in currentItem.answer %}{% if answer.value.code = '20468' %}Neck{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20541' %}Neck angiography{% endif %}{% if answer.value.code = '20487' %}Soft Tissue Neck{% endif %}{% if answer.value.code = '20488' %}Brachial plexus{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea_brachial' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_neck_specificarea_brachial' and answer.exists()) %}{% if currentItem.answer.exists() %}Brachial Plexus: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine' and answer.exists()) %}{% if currentItem.answer.exists() %}Spine {% for answer in currentItem.answer %}{% if answer.value.code = '20469' %}Spine{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_spine_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20489' %}Whole Spine{% endif %}{% if answer.value.code = '20490' %}Cervical Spine{% endif %}{% if answer.value.code = '20491' %}Thoracic Spine{% endif %}{% if answer.value.code = '20492' %}Lumbar Spine{% endif %}{% if answer.value.code = '20493' %}Sacrum/Coccyx{% endif %}{% if answer.value.code = '20494' %}Sacroiliac Joints{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax' and answer.exists()) %}{% if currentItem.answer.exists() %}Thorax {% for answer in currentItem.answer %}{% if answer.value.code = '20470' %}Thorax{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20495' %}Chest{% endif %}{% if answer.value.code = '20496' %}Chest wall{% endif %}{% if answer.value.code = '20497' %}Pulmonary arteries{% endif %}{% if answer.value.code = '20498' %}Sternoclavicular joints{% endif %}{% if answer.value.code = '20499' %}Sternum{% endif %}{% if answer.value.code = '20542' %}Chest Angiography{% endif %}{% if answer.value.code = '20501' %}Thoracic Outlet{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_thorax_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen' and answer.exists()) %}{% if currentItem.answer.exists() %}Abdomen {% for answer in currentItem.answer %}{% if answer.value.code = '20471' %}Abdomen{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '21398' %}Abdomen Pelvis Angiography{% endif %}{% if answer.value.code = '20503' %}Abdominal wall{% endif %}{% if answer.value.code = '20504' %}Adrenal glands{% endif %}{% if answer.value.code = '20505' %}Biliary and pancreatic ducts{% endif %}{% if answer.value.code = '20506' %}Enterography{% endif %}{% if answer.value.code = '20507' %}Kidneys{% endif %}{% if answer.value.code = '20508' %}Liver{% endif %}{% if answer.value.code = '20509' %}Pancreas{% endif %}{% if answer.value.code = '20510' %}Renal artery{% endif %}{% if answer.value.code = '20511' %}Urography{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_abdomen_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis' and answer.exists()) %}{% if currentItem.answer.exists() %}Pelvis {% for answer in currentItem.answer %}{% if answer.value.code = '20472' %}Pelvis{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20512' %}Bladder{% endif %}{% if answer.value.code = '20513' %}Gynecology (Uterus/ Ovaries/ Adnexal){% endif %}{% if answer.value.code = '20514' %}Iliac arteries{% endif %}{% if answer.value.code = '20515' %}Piriformis{% endif %}{% if answer.value.code = '20516' %}Prostate{% endif %}{% if answer.value.code = '20517' %}Rectum/ Anal{% endif %}{% if answer.value.code = '20518' %}Urogenital (Testicular/ Penile){% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_pelvis_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal' and answer.exists()) %}{% if currentItem.answer.exists() %}Musculoskeletal {% for answer in currentItem.answer %}{% if answer.value.code = '20473' %}Musculoskeletal{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20519' %}Shoulder{% endif %}{% if answer.value.code = '20520' %}Humerus{% endif %}{% if answer.value.code = '20521' %}Elbow{% endif %}{% if answer.value.code = '20522' %}Forearm{% endif %}{% if answer.value.code = '20523' %}Wrist{% endif %}{% if answer.value.code = '20524' %}Hand{% endif %}{% if answer.value.code = '20525' %}Finger{% endif %}{% if answer.value.code = '20526' %}Bony Pelvis{% endif %}{% if answer.value.code = '20527' %}Hip{% endif %}{% if answer.value.code = '20528' %}Femur / Thigh{% endif %}{% if answer.value.code = '20529' %}Knee{% endif %}{% if answer.value.code = '20530' %}Tibia and Fibula{% endif %}{% if answer.value.code = '20531' %}Ankle{% endif %}{% if answer.value.code = '20532' %}Foot{% endif %}{% if answer.value.code = '20533' %}Toe{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_shoulder' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_shoulder' and answer.exists()) %}{% if currentItem.answer.exists() %}Shoulder: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_humerus' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_humerus' and answer.exists()) %}{% if currentItem.answer.exists() %}Humerus: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_elbow' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_elbow' and answer.exists()) %}{% if currentItem.answer.exists() %}Elbow: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_elbow_arthrogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_elbow_arthrogram' and answer.exists()) %}{% if currentItem.answer.exists() %}With {% for answer in currentItem.answer %}{% if answer.value.code = '20535' %}Arthrogram{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_forearm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_forearm' and answer.exists()) %}{% if currentItem.answer.exists() %}Forearm: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_wrist' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_wrist' and answer.exists()) %}{% if currentItem.answer.exists() %}Wrist: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_wrist_arthrogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_wrist_arthrogram' and answer.exists()) %}{% if currentItem.answer.exists() %}With {% for answer in currentItem.answer %}{% if answer.value.code = '20536' %}Arthrogram{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hand' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hand' and answer.exists()) %}{% if currentItem.answer.exists() %}Hand: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_finger' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_finger' and answer.exists()) %}{% if currentItem.answer.exists() %}Finger: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hip' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hip' and answer.exists()) %}{% if currentItem.answer.exists() %}Hip: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hip_arthrogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_hip_arthrogram' and answer.exists()) %}{% if currentItem.answer.exists() %}With {% for answer in currentItem.answer %}{% if answer.value.code = '20537' %}Arthrogram{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_femur' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_femur' and answer.exists()) %}{% if currentItem.answer.exists() %}Femur: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_knee' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_knee' and answer.exists()) %}{% if currentItem.answer.exists() %}Knee: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_knee_arthrogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_knee_arthrogram' and answer.exists()) %}{% if currentItem.answer.exists() %}With {% for answer in currentItem.answer %}{% if answer.value.code = '20538' %}Arthrogram{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_tibia' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_tibia' and answer.exists()) %}{% if currentItem.answer.exists() %}Tibia / Fibula: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_ankle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_ankle' and answer.exists()) %}{% if currentItem.answer.exists() %}Ankle: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_ankle_arthrogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_ankle_arthrogram' and answer.exists()) %}{% if currentItem.answer.exists() %}With {% for answer in currentItem.answer %}{% if answer.value.code = '20539' %}Arthrogram{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_foot' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_foot' and answer.exists()) %}{% if currentItem.answer.exists() %}Foot: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_toe' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_musculoskeletal_specificarea_toe' and answer.exists()) %}{% if currentItem.answer.exists() %}Toe: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial' and answer.exists()) %}{% if currentItem.answer.exists() %}Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '20474' %}Angiography{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20540' %}Head Angiography{% endif %}{% if answer.value.code = '20541' %}Neck Angiography{% endif %}{% if answer.value.code = '20542' %}Chest Angiography{% endif %}{% if answer.value.code = '20543' %}Abdomen Angiography{% endif %}{% if answer.value.code = '20544' %}Pelvis Angiography{% endif %}{% if answer.value.code = '20545' %}Upper Extremity Angiography{% endif %}{% if answer.value.code = '20546' %}Lower Extremity Angiography{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyarterial_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiography_specificarea_upper_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiography_specificarea_upper_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Upper Extremity Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyl_specificarea_lower_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_angiographyl_specificarea_lower_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Lower Extremity Angiography {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast' and answer.exists()) %}{% if currentItem.answer.exists() %}Breast {% for answer in currentItem.answer %}{% if answer.value.code = '20476' %}Breast{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20554' %}Diagnostic{% endif %}{% if answer.value.code = '20555' %}Implant{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_diagnostic' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_diagnostic' and answer.exists()) %}{% if currentItem.answer.exists() %}Diagnostic {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_breastimplant' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_breast_specificarea_breastimplant' and answer.exists()) %}{% if currentItem.answer.exists() %}Breast Implant: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_cardiac' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_cardiac' and answer.exists()) %}{% if currentItem.answer.exists() %}Cardiac {% for answer in currentItem.answer %}{% if answer.value.code = '20477' %}Cardiac{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other {% for answer in currentItem.answer %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_other_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_MRI_other_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_MRI_clinicalindication_MRIrefnote').exists() %}MRI Request: Clinical History / Indication {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_MRI_clinicalindication_MRIrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_MRI_clinicalindication_text' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRI_clinicalindication_text' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_XRAY_group_XRAYrefnote').exists() %}X-Ray Exam/Region(s) of Interest: {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_XRAY_group_XRAYrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest' and answer.exists()) %}{% if currentItem.answer.exists() %}Chest (default Chest 2 views) {% for answer in currentItem.answer %}{% if answer.value.code = '20556' %}Chest (default Chest 2 views){% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20566' %}One view (PA){% endif %}{% if answer.value.code = '20567' %}Two Views (PA, Lat){% endif %}{% if answer.value.code = '20568' %}Three views (PA inspiration, PA expiration, Lat){% endif %}{% if answer.value.code = '20569' %}Sternum{% endif %}{% if answer.value.code = '20570' %}Ribs{% endif %}{% if answer.value.code = '20571' %}Thoracic inlet{% endif %}{% if answer.value.code = '20572' %}Sternoclavicular Joints{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_ribs' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_chest_ribs' and answer.exists()) %}{% if currentItem.answer.exists() %}Ribs: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen' and answer.exists()) %}{% if currentItem.answer.exists() %}Abdomen {% for answer in currentItem.answer %}{% if answer.value.code = '20557' %}Abdomen{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_specifcarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_specifcarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20573' %}One view (Supine){% endif %}{% if answer.value.code = '20574' %}One view (Upright){% endif %}{% if answer.value.code = '20575' %}KUB (Kidney Ureters Bladder){% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_specifcarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_abdomen_specifcarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine' and answer.exists()) %}{% if currentItem.answer.exists() %}Spine {% for answer in currentItem.answer %}{% if answer.value.code = '20558' %}Spine{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20576' %}Cervical{% endif %}{% if answer.value.code = '20577' %}Cervical spine flexion extension{% endif %}{% if answer.value.code = '20578' %}Thoracic{% endif %}{% if answer.value.code = '20579' %}Lumbar{% endif %}{% if answer.value.code = '20580' %}Lumbar spine flexion extension{% endif %}{% if answer.value.code = '20581' %}Sacrum{% endif %}{% if answer.value.code = '20582' %}Coccyx{% endif %}{% if answer.value.code = '20583' %}Sacroiliac joints{% endif %}{% if answer.value.code = '20584' %}Scoliosis spine{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_specifcarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_specifcarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_scoliosisviews' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_spine_scoliosisviews' and answer.exists()) %}{% if currentItem.answer.exists() %}Scoliosis spine views: {% for answer in currentItem.answer %}{% if answer.value = 'PA views only' %}PA views only{% endif %}{% if answer.value = 'PA and Lateral views' %}PA and Lateral views{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head' and answer.exists()) %}{% if currentItem.answer.exists() %}Head and Neck {% for answer in currentItem.answer %}{% if answer.value.code = '20559' %}Head and Neck{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20585' %}Skull{% endif %}{% if answer.value.code = '20586' %}Orbits{% endif %}{% if answer.value.code = '20587' %}Neck for soft tissue{% endif %}{% if answer.value.code = '20588' %}Mastoids{% endif %}{% if answer.value.code = '20589' %}Nasal bones{% endif %}{% if answer.value.code = '20590' %}Facal bones{% endif %}{% if answer.value.code = '20591' %}Mandible{% endif %}{% if answer.value.code = '20592' %}Temporomandibular joints{% endif %}{% if answer.value.code = '20593' %}Sinus{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea_orbit' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_head_specifcarea_orbit' and answer.exists()) %}{% if currentItem.answer.exists() %}Orbits exams: {% for answer in currentItem.answer %}{% if answer.value.code = '20594' %}Trauma or injury{% endif %}{% if answer.value.code = '20595' %}Eye for foreign body{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities' and answer.exists()) %}{% if currentItem.answer.exists() %}Upper Extremities {% for answer in currentItem.answer %}{% if answer.value.code = '20560' %}Upper Extremities{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20596' %}Shoulder{% endif %}{% if answer.value.code = '20597' %}Clavicle{% endif %}{% if answer.value.code = '20598' %}Acromioclavicular joints{% endif %}{% if answer.value.code = '20572' %}Sternoclavicular Joints{% endif %}{% if answer.value.code = '20599' %}Scapula{% endif %}{% if answer.value.code = '20600' %}Humerus{% endif %}{% if answer.value.code = '20601' %}Elbow{% endif %}{% if answer.value.code = '20602' %}Forearm{% endif %}{% if answer.value.code = '20603' %}Wrist{% endif %}{% if answer.value.code = '20604' %}Scaphoid{% endif %}{% if answer.value.code = '20605' %}Hand{% endif %}{% if answer.value.code = '20606' %}Finger{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_shoulder' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_shoulder' and answer.exists()) %}{% if currentItem.answer.exists() %}Shoulder: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_clavicle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_clavicle' and answer.exists()) %}{% if currentItem.answer.exists() %}Clavicle: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_acromioclavicular' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_acromioclavicular' and answer.exists()) %}{% if currentItem.answer.exists() %}Acromioclavicular joints: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_scapula' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_scapula' and answer.exists()) %}{% if currentItem.answer.exists() %}Scapula: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_humerus' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_humerus' and answer.exists()) %}{% if currentItem.answer.exists() %}Humerus: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_elbow' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_elbow' and answer.exists()) %}{% if currentItem.answer.exists() %}Elbow: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_forearm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_forearm' and answer.exists()) %}{% if currentItem.answer.exists() %}Forearm: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_wrist' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_wrist' and answer.exists()) %}{% if currentItem.answer.exists() %}Wrist: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_scaphold' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_scaphold' and answer.exists()) %}{% if currentItem.answer.exists() %}Scaphold: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_hand' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_hand' and answer.exists()) %}{% if currentItem.answer.exists() %}Hand: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_finger' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_upperextremities_specifcarea_finger' and answer.exists()) %}{% if currentItem.answer.exists() %}Finger: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities' and answer.exists()) %}{% if currentItem.answer.exists() %}Lower Extremities {% for answer in currentItem.answer %}{% if answer.value.code = '20561' %}Lower Extremities{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20607' %}Pelvis{% endif %}{% if answer.value.code = '20608' %}Hip{% endif %}{% if answer.value.code = '20609' %}Femur{% endif %}{% if answer.value.code = '20610' %}Knee{% endif %}{% if answer.value.code = '20611' %}Patella{% endif %}{% if answer.value.code = '20612' %}Tibia and fibula{% endif %}{% if answer.value.code = '20613' %}Ankle{% endif %}{% if answer.value.code = '20614' %}Foot{% endif %}{% if answer.value.code = '20615' %}Calcaneus{% endif %}{% if answer.value.code = '20616' %}Toes{% endif %}{% if answer.value.code = '20617' %}Leg length{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_hip' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_hip' and answer.exists()) %}{% if currentItem.answer.exists() %}Hip: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_femur' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_femur' and answer.exists()) %}{% if currentItem.answer.exists() %}Femur: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_knee' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_knee' and answer.exists()) %}{% if currentItem.answer.exists() %}Knee: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_patella' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_patella' and answer.exists()) %}{% if currentItem.answer.exists() %}Patella: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_tibia' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_tibia' and answer.exists()) %}{% if currentItem.answer.exists() %}Tibia and fibula: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_ankle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_ankle' and answer.exists()) %}{% if currentItem.answer.exists() %}Ankle: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_foot' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_foot' and answer.exists()) %}{% if currentItem.answer.exists() %}Foot: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_calcaneus' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_calcaneus' and answer.exists()) %}{% if currentItem.answer.exists() %}Calcaneus: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_toe' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_lowerextremities_specificarea_toe' and answer.exists()) %}{% if currentItem.answer.exists() %}Toe: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_mammogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_mammogram' and answer.exists()) %}{% if currentItem.answer.exists() %}Mammogram (Non-OBSP) {% for answer in currentItem.answer %}{% if answer.value.code = '20562' %}Mammogram (Non-OBSP){% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% capture childItems %}{% if answer.item.where(linkId = 'medicalImaging_examRequest_XRAY_mammogram_specifcarea' and answer.exists()).exists() %}{% for currentItem in answer.item.where(linkId = 'medicalImaging_examRequest_XRAY_mammogram_specifcarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Mammogram: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_boneage' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_boneage' and answer.exists()) %}{% if currentItem.answer.exists() %}Bone Age {% for answer in currentItem.answer %}{% if answer.value.code = '20563' %}Bone Age{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey' and answer.exists()) %}{% if currentItem.answer.exists() %}Survey {% for answer in currentItem.answer %}{% if answer.value.code = '20564' %}Survey{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20618' %}Metabolic{% endif %}{% if answer.value.code = '20619' %}Metastatic{% endif %}{% if answer.value.code = '20620' %}Rheumatoid{% endif %}{% if answer.value.code = '20621' %}Babygram{% endif %}{% if answer.value.code = '20617' %}Leg length{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_survey_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric' and answer.exists()) %}{% if currentItem.answer.exists() %}Gastric and Fluoroscopic imaging {% for answer in currentItem.answer %}{% if answer.value.code = '20565' %}Gastric and Fluoroscopic imaging{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20622' %}Gastrointestinal tract{% endif %}{% if answer.value.code = '20623' %}Retrograde urethrogram{% endif %}{% if answer.value.code = '20624' %}Cystourethrogram{% endif %}{% if answer.value.code = '20625' %}Hysterosalpingogram{% endif %}{% if answer.value.code = '20626' %}Sinogram{% endif %}{% if answer.value.code = '20627' %}Musculoskeletal injections{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_gastro' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_gastro' and answer.exists()) %}{% if currentItem.answer.exists() %}Gastrointestinal tract exams: {% for answer in currentItem.answer %}{% if answer.value.code = '20629' %}Barium swallow{% endif %}{% if answer.value.code = '20628' %}Modified barium swallow (Video fluoroscope swallowing exam){% endif %}{% if answer.value.code = '20630' %}Upper GI series (Esophagus, stomach and duodenum){% endif %}{% if answer.value.code = '20631' %}Small bowel follow through{% endif %}{% if answer.value.code = '20632' %}Barium enema{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_gastro_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_gastro_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_cysto' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_cysto' and answer.exists()) %}{% if currentItem.answer.exists() %}Cystourethrogram: {% for answer in currentItem.answer %}{% if answer.value.code = '20633' %}Stress{% endif %}{% if answer.value.code = '20634' %}Voiding{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_sinogram' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_sinogram' and answer.exists()) %}{% if currentItem.answer.exists() %}Sinogram: specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_musculoskeletal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_gastric_specifcarea_musculoskeletal' and answer.exists()) %}{% if currentItem.answer.exists() %}Musculoskeletal injection: specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_XRAY_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other {% for answer in currentItem.answer %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% capture childItems %}{% if answer.item.where(linkId = 'medicalImaging_examRequest_XRAY_other_specify' and answer.exists()).exists() %}{% for currentItem in answer.item.where(linkId = 'medicalImaging_examRequest_XRAY_other_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Other: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_XRAYrefnote').exists() %}X-Ray Request: Clinical History / Indication {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_XRAYrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_text' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_text' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_views' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_XRAY_clinicalindication_views' and answer.exists()) %}{% if currentItem.answer.exists() %}Additional relevant information (e.g. request specific views) {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_US_group_USrefnote').exists() %}Ultrasound Exam/Region(s) of Interest: {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_US_group_USrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen' and answer.exists()) %}{% if currentItem.answer.exists() %}Abdomen {% for answer in currentItem.answer %}{% if answer.value.code = '20635' %}Abdomen{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20643' %}Complete abdomen{% endif %}{% if answer.value.code = '20644' %}Appendix{% endif %}{% if answer.value.code = '20645' %}Gallbladder{% endif %}{% if answer.value.code = '20646' %}Kidney Ureters Bladder{% endif %}{% if answer.value.code = '20647' %}Liver{% endif %}{% if answer.value.code = '20648' %}Liver elastography{% endif %}{% if answer.value.code = '20649' %}Pancreas{% endif %}{% if answer.value.code = '20650' %}Portal hypertension{% endif %}{% if answer.value.code = '20651' %}Renal{% endif %}{% if answer.value.code = '20652' %}Right upper quadrant{% endif %}{% if answer.value.code = '20653' %}Spleen{% endif %}{% if answer.value.code = '20654' %}Abdomen contrast{% endif %}{% if answer.value.code = '20655' %}Abdominal wall{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_abdomen_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis' and answer.exists()) %}{% if currentItem.answer.exists() %}Pelvis {% for answer in currentItem.answer %}{% if answer.value.code = '20636' %}Pelvis{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20656' %}Complete pelvis{% endif %}{% if answer.value.code = '20657' %}Pelvis transabdominal{% endif %}{% if answer.value.code = '20658' %}Female pelvis (transvaginal){% endif %}{% if answer.value.code = '20659' %}Follicular monitoring{% endif %}{% if answer.value.code = '20660' %}Limited non-pregnancy (for IUD insertion placement check){% endif %}{% if answer.value.code = '20661' %}Saline Infusion Sonohysterography{% endif %}{% if answer.value.code = '20662' %}Male pelvis (Transrectal){% endif %}{% if answer.value.code = '20663' %}Prostate{% endif %}{% if answer.value.code = '20664' %}Penile{% endif %}{% if answer.value.code = '20665' %}Testicles/Scrotum{% endif %}{% if answer.value.code = '20666' %}Bladder{% endif %}{% if answer.value.code = '20667' %}Groin{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea_groin' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_pelvis_specificarea_groin' and answer.exists()) %}{% if currentItem.answer.exists() %}Groin: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical' and answer.exists()) %}{% if currentItem.answer.exists() %}Obstetrical {% for answer in currentItem.answer %}{% if answer.value.code = '20637' %}Obstetrical{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_pregnancytype' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_pregnancytype' and answer.exists()) %}{% if currentItem.answer.exists() %}Pregnancy type: {% for answer in currentItem.answer %}{% if answer.value.code = '20668' %}Singleton{% endif %}{% if answer.value.code = '20669' %}Twins{% endif %}{% if answer.value.code = '20670' %}Triplets{% endif %}{% if answer.value.code = '20671' %}Unknown{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_pregnancytype_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_pregnancytype_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20672' %}Dating (<16 weeks){% endif %}{% if answer.value.code = '20673' %}Prenatal screening (NT/eFTS) 11-14 weeks{% endif %}{% if answer.value.code = '20674' %}Anatomy (20 week scan){% endif %}{% if answer.value.code = '20675' %}2nd or 3rd trimester scan{% endif %}{% if answer.value.code = '20676' %}Biophysical profile{% endif %}{% if answer.value.code = '20677' %}Growth{% endif %}{% if answer.value.code = '20678' %}Cervical length{% endif %}{% if answer.value.code = '20679' %}Multi-gestational study{% endif %}{% if answer.value.code = '20680' %}High risk pregnancy{% endif %}{% if answer.value.code = '20681' %}Uterine artery doppler studies{% endif %}{% if answer.value.code = '20682' %}Umbilical artery doppler studies{% endif %}{% if answer.value.code = '20683' %}Fetal doppler{% endif %}{% if answer.value.code = '20745' %}With transvaginal{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_anatomy' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_anatomy' and answer.exists()) %}{% if currentItem.answer.exists() %}Anatomy (20 week scan) additional option: {% for answer in currentItem.answer %}{% if answer.value.code = '20684' %}Report sex{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_highrisk' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_obstetrical_specificarea_highrisk' and answer.exists()) %}{% if currentItem.answer.exists() %}High-Risk Pregnancy Trimester: {% for answer in currentItem.answer %}{% if answer.value.code = '20685' %}1st Trimester{% endif %}{% if answer.value.code = '20686' %}2nd and 3rd Trimester{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal' and answer.exists()) %}{% if currentItem.answer.exists() %}Neonatal and Paediatric {% for answer in currentItem.answer %}{% if answer.value.code = '20638' %}Neonatal and Paediatric{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20689' %}Brain{% endif %}{% if answer.value.code = '20688' %}Spine{% endif %}{% if answer.value.code = '20691' %}Pylorus and Hypertrophic Pyloric Stenosis{% endif %}{% if answer.value.code = '20692' %}Bowel{% endif %}{% if answer.value.code = '20644' %}Appendix{% endif %}{% if answer.value.code = '20690' %}Hips{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_neonatal_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal' and answer.exists()) %}{% if currentItem.answer.exists() %}Musculoskeletal {% for answer in currentItem.answer %}{% if answer.value.code = '20639' %}Musculoskeletal{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20712' %}Shoulders{% endif %}{% if answer.value.code = '20713' %}Rotator cuff{% endif %}{% if answer.value.code = '20710' %}Biceps{% endif %}{% if answer.value.code = '20711' %}Triceps{% endif %}{% if answer.value.code = '20709' %}Elbow{% endif %}{% if answer.value.code = '20707' %}Carpal tunnel{% endif %}{% if answer.value.code = '20706' %}Wrist{% endif %}{% if answer.value.code = '20705' %}Hand{% endif %}{% if answer.value.code = '20715' %}Finger(s){% endif %}{% if answer.value.code = '20704' %}Gluteal region{% endif %}{% if answer.value.code = '20703' %}Hip{% endif %}{% if answer.value.code = '20702' %}Thigh/Hamstrings{% endif %}{% if answer.value.code = '20701' %}Quadriceps tendon{% endif %}{% if answer.value.code = '20699' %}Patellar tendon{% endif %}{% if answer.value.code = '20698' %}Knee{% endif %}{% if answer.value.code = '20700' %}Popliteal fossa{% endif %}{% if answer.value.code = '20697' %}Calf/Lower leg/Gastrocnemius{% endif %}{% if answer.value.code = '20696' %}Achilles{% endif %}{% if answer.value.code = '20695' %}Ankle{% endif %}{% if answer.value.code = '20693' %}Foot{% endif %}{% if answer.value.code = '20694' %}Plantar fascia{% endif %}{% if answer.value.code = '20714' %}Toe(s){% endif %}{% if answer.value.code = '20716' %}Palpable masses{% endif %}{% if answer.value.code = '20717' %}Foreign body{% endif %}{% if answer.value.code = '20708' %}Forearm{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_shoulder' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_shoulder' and answer.exists()) %}{% if currentItem.answer.exists() %}Shoulder: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_rotatorcuff' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_rotatorcuff' and answer.exists()) %}{% if currentItem.answer.exists() %}Rotator cuff: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_biceps' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_biceps' and answer.exists()) %}{% if currentItem.answer.exists() %}Biceps: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_triceps' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_triceps' and answer.exists()) %}{% if currentItem.answer.exists() %}Triceps: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_elbow' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_elbow' and answer.exists()) %}{% if currentItem.answer.exists() %}Elbow: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_forearm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_forearm' and answer.exists()) %}{% if currentItem.answer.exists() %}Forearm: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_carpaltunnel' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_carpaltunnel' and answer.exists()) %}{% if currentItem.answer.exists() %}Carpal tunnel: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_wrist' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_wrist' and answer.exists()) %}{% if currentItem.answer.exists() %}Wrist: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_hand' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_hand' and answer.exists()) %}{% if currentItem.answer.exists() %}Hand: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger' and answer.exists()) %}{% if currentItem.answer.exists() %}Finger(s): {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger_left' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger_left' and answer.exists()) %}{% if currentItem.answer.exists() %}Left digit(s): {% for answer in currentItem.answer %}{% if answer.value = '1' %}1{% endif %}{% if answer.value = '2' %}2{% endif %}{% if answer.value = '3' %}3{% endif %}{% if answer.value = '4' %}4{% endif %}{% if answer.value = '5' %}5{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger_right' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_finger_right' and answer.exists()) %}{% if currentItem.answer.exists() %}Right digit(s): {% for answer in currentItem.answer %}{% if answer.value = '1' %}1{% endif %}{% if answer.value = '2' %}2{% endif %}{% if answer.value = '3' %}3{% endif %}{% if answer.value = '4' %}4{% endif %}{% if answer.value = '5' %}5{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_gluteal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_gluteal' and answer.exists()) %}{% if currentItem.answer.exists() %}Gluteal region: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_hip' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_hip' and answer.exists()) %}{% if currentItem.answer.exists() %}Hip: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_thigh' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_thigh' and answer.exists()) %}{% if currentItem.answer.exists() %}Thigh/Hamstrings: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_quadriceps' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_quadriceps' and answer.exists()) %}{% if currentItem.answer.exists() %}Quadriceps tendon: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_patellar' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_patellar' and answer.exists()) %}{% if currentItem.answer.exists() %}Patellar tendon: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_knee' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_knee' and answer.exists()) %}{% if currentItem.answer.exists() %}Knee: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_popliteal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_popliteal' and answer.exists()) %}{% if currentItem.answer.exists() %}Popliteal fossa: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_calf' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_calf' and answer.exists()) %}{% if currentItem.answer.exists() %}Calf/Lower leg/Gastrocnemius: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_achilles' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_achilles' and answer.exists()) %}{% if currentItem.answer.exists() %}Achilles: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_ankle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_ankle' and answer.exists()) %}{% if currentItem.answer.exists() %}Ankle: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_ankle_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_ankle_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Ankle specify: {% for answer in currentItem.answer %}{% if answer.value = 'Medial' %}Medial{% endif %}{% if answer.value = 'Lateral' %}Lateral{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_foot' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_foot' and answer.exists()) %}{% if currentItem.answer.exists() %}Foot: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_plantar' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_plantar' and answer.exists()) %}{% if currentItem.answer.exists() %}Plantar fascia: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe' and answer.exists()) %}{% if currentItem.answer.exists() %}Toe: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe_left' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe_left' and answer.exists()) %}{% if currentItem.answer.exists() %}Left digit(s): {% for answer in currentItem.answer %}{% if answer.value = '1' %}1{% endif %}{% if answer.value = '2' %}2{% endif %}{% if answer.value = '3' %}3{% endif %}{% if answer.value = '4' %}4{% endif %}{% if answer.value = '5' %}5{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe_right' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_toe_right' and answer.exists()) %}{% if currentItem.answer.exists() %}Right digits(s): {% for answer in currentItem.answer %}{% if answer.value = '1' %}1{% endif %}{% if answer.value = '2' %}2{% endif %}{% if answer.value = '3' %}3{% endif %}{% if answer.value = '4' %}4{% endif %}{% if answer.value = '5' %}5{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_palpablemass' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_palpablemass' and answer.exists()) %}{% if currentItem.answer.exists() %}Palpable masses specify: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_foreignbody' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_musculoskeletal_specificarea_foreignbody' and answer.exists()) %}{% if currentItem.answer.exists() %}Foreign body specify: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular' and answer.exists()) %}{% if currentItem.answer.exists() %}Vascular {% for answer in currentItem.answer %}{% if answer.value.code = '20640' %}Vascular{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20718' %}Upper extremity arterial{% endif %}{% if answer.value.code = '20719' %}Upper extremity venous{% endif %}{% if answer.value.code = '20720' %}Lower extremity arterial{% endif %}{% if answer.value.code = '20721' %}Lower extremity venous thrombosis{% endif %}{% if answer.value.code = '20722' %}Lower extremity venous reflux{% endif %}{% if answer.value.code = '20723' %}Abdominal aortic aneurysm screen{% endif %}{% if answer.value.code = '20724' %}Ankle brachial index{% endif %}{% if answer.value.code = '20725' %}Arterial venous fistula{% endif %}{% if answer.value.code = '20726' %}Carotid{% endif %}{% if answer.value.code = '20727' %}Inferior vena cava{% endif %}{% if answer.value.code = '20728' %}Portal vein{% endif %}{% if answer.value.code = '20729' %}Renal arteries{% endif %}{% if answer.value.code = '20730' %}Superior mesenteric artery (SMA){% endif %}{% if answer.value.code = '20731' %}Temporal arteries{% endif %}{% if answer.value.code = '21375' %}Thoracic outlet syndrome{% endif %}{% if answer.value.code = '20732' %}Venous mapping{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_uea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_uea' and answer.exists()) %}{% if currentItem.answer.exists() %}Upper extremity arterial ultrasound: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_uev' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_uev' and answer.exists()) %}{% if currentItem.answer.exists() %}Upper extremity venous ultrasound: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_lea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_lea' and answer.exists()) %}{% if currentItem.answer.exists() %}Lower extremity arterial ultrasound: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_lev' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_lev' and answer.exists()) %}{% if currentItem.answer.exists() %}Lower extremity venous thrombosis ultrasound: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_levr' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_levr' and answer.exists()) %}{% if currentItem.answer.exists() %}Lower extremity venous reflux ultrasound: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_ankle' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_ankle' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify extremity: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificside_avf' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificside_avf' and answer.exists()) %}{% if currentItem.answer.exists() %}AVF specify side: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_avf' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_avf' and answer.exists()) %}{% if currentItem.answer.exists() %}AVF specify area: {% for answer in currentItem.answer %}{% if answer.value.code = '21378' %}Arm{% endif %}{% if answer.value.code = '21379' %}Leg{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_sma' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_sma' and answer.exists()) %}{% if currentItem.answer.exists() %}SMA specify: {% for answer in currentItem.answer %}{% if answer.value.code = '21381' %}Fasting{% endif %}{% if answer.value.code = '21382' %}Post-prandial{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_temporal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_temporal' and answer.exists()) %}{% if currentItem.answer.exists() %}Temporal arteries: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_thoracicoutlet' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_thoracicoutlet' and answer.exists()) %}{% if currentItem.answer.exists() %}Thoracic outlet syndrome: {% for answer in currentItem.answer %}{% if answer.value.code = '21376' %}Arterial{% endif %}{% if answer.value.code = '21377' %}Venous{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_venous' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_vascular_specificarea_venous' and answer.exists()) %}{% if currentItem.answer.exists() %}Venous mapping: Specify extremity {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head' and answer.exists()) %}{% if currentItem.answer.exists() %}Head and Neck {% for answer in currentItem.answer %}{% if answer.value.code = '20641' %}Head and Neck{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20733' %}Neck/Salivary gland{% endif %}{% if answer.value.code = '20734' %}Lymph nodes{% endif %}{% if answer.value.code = '20735' %}Thyroid{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_neck' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_neck' and answer.exists()) %}{% if currentItem.answer.exists() %}Neck/Salivary gland: Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_lymph' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_head_specificarea_lymph' and answer.exists()) %}{% if currentItem.answer.exists() %}Lymph nodes: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast' and answer.exists()) %}{% if currentItem.answer.exists() %}Breast and Axilla {% for answer in currentItem.answer %}{% if answer.value.code = '20642' %}Breast and Axilla{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20736' %}Breast{% endif %}{% if answer.value.code = '20737' %}Axilla{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_breast' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_breast' and answer.exists()) %}{% if currentItem.answer.exists() %}Breast: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_axilla' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_breast_specificarea_axilla' and answer.exists()) %}{% if currentItem.answer.exists() %}Axilla: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc' and answer.exists()) %}{% if currentItem.answer.exists() %}Miscellaneous {% for answer in currentItem.answer %}{% if answer.value = 'Miscellaneous' %}Miscellaneous{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_group').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea' and answer.exists()) %}{% if currentItem.answer.exists() %}Specific area of interest {% for answer in currentItem.answer %}{% if answer.value.code = '20738' %}Chest{% endif %}{% if answer.value.code = '20739' %}Chest wall (mass){% endif %}{% if answer.value.code = '20740' %}Soft tissue{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Other specific area of interest {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_chest' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_chest' and answer.exists()) %}{% if currentItem.answer.exists() %}Chest: {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_softtissue' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_US_misc_specificarea_softtissue' and answer.exists()) %}{% if currentItem.answer.exists() %}Soft tissue: Specify {% for answer in currentItem.answer %}{% if answer.value.code = '21321' %}Left{% endif %}{% if answer.value.code = '21322' %}Right{% endif %}{% if answer.value.code = '21323' %}Bilateral{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_US_clinicalindication_USrefnote').exists() %}Ultrasound Request: Clinical History / Indication {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_US_clinicalindication_USrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_US_clinicalindication_text' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_US_clinicalindication_text' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_group_BMDrefnote' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_group_BMDrefnote' and answer.exists()) %}{% if currentItem.answer.exists() %}Select BMD Exam of Interest: {% for answer in currentItem.answer %}{% if answer.value.code = '20741' %}Baseline{% endif %}{% if answer.value.code = '20742' %}Low Risk{% endif %}{% if answer.value.code = '20743' %}High Risk{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_Specify' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_Specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify: {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_previous_date' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_previous_date' and answer.exists()) %}{% if currentItem.answer.exists() %}Date of most recent BMD (Year and Month if known): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_previous_location' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_previous_location' and answer.exists()) %}{% if currentItem.answer.exists() %}Location of most recent BMD: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_BMD_clinicalindication_BMDrefnote').exists() %}BMD Request: Clinical History / Indication {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_BMD_clinicalindication_BMDrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_BMD_clinicalindication_text' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_BMD_clinicalindication_text' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_group').exists() %}Previous Relevant BMD {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Date' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Date' and answer.exists()) %}{% if currentItem.answer.exists() %}Date of most recent BMD (Year and Month if known): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Location' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Location' and answer.exists()) %}{% if currentItem.answer.exists() %}Location of most recent BMD: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Attachment' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_examRequest_BMD_Previous_Attachment' and answer.exists()) %}{% if currentItem.answer.exists() %}Add Attachments {% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_MRIsafety_group_MRIrefnote').exists() %}MRI Safety Screening {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_MRIsafety_group_MRIrefnote') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metalfragments' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metalfragments' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '21296' %}Has metal fragments in eye(s)/body{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '21297' %}Has active electronic implants (e.g. Cardiac Implantable Electronic Device, Neurostimulator, Cochlear Implant, Medication Pump, etc.) or retained parts (e.g. leads, etc.):{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{% if answer.value.code = '21299' %}CIED{% endif %}{% if answer.value.code = '21300' %}Neurostimulator{% endif %}{% if answer.value.code = '21301' %}Cochlear Implant{% endif %}{% if answer.value.code = '21302' %}Medication Pump{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_otherspecify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_otherspecify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_implantdetails' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_electronicimplant_implantdetails' and answer.exists()) %}{% if currentItem.answer.exists() %}Implant details {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '21298' %}Has other metal containing devices (e.g. Aneurysm Clip, IUD, Tissue Expander, Shunt, Stent, Coil, Traction Device, Glucose Monitor, etc.), metal foreign bodies (Shrapnel, Bullets, Subdermal Piercings, Etc), or orthopedic device:{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices_specify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{% if answer.value.code = '21303' %}Aneurysm Clip{% endif %}{% if answer.value.code = '21304' %}Coil{% endif %}{% if answer.value.code = '21305' %}Glucose Monitor{% endif %}{% if answer.value.code = '21306' %}Heart Valve{% endif %}{% if answer.value.code = '21307' %}Copper or Stainless Steel IUD{% endif %}{% if answer.value.code = '21308' %}Orthopedic Devices{% endif %}{% if answer.value.code = '21309' %}Pessary{% endif %}{% if answer.value.code = '21310' %}Prosthesis{% endif %}{% if answer.value.code = '21311' %}Shunt{% endif %}{% if answer.value.code = '21312' %}Stent{% endif %}{% if answer.value.code = '21313' %}Subdermal Piercings{% endif %}{% if answer.value.code = '21314' %}Tissue Expander{% endif %}{% if answer.value.code = '21315' %}Traction Device{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if answer.value.code = '21399' %}None of the above{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices_otherspecify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_metaldevices_otherspecify' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'MRI_safety_implantDetails' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'MRI_safety_implantDetails' and answer.exists()) %}{% if currentItem.answer.exists() %}Implant details {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'MRI_safety_none' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'MRI_safety_none' and answer.exists()) %}{% if currentItem.answer.exists() %}None of the above {% for answer in currentItem.answer %}{% if answer.value = 'None of the above' %}None of the above{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_MRIsafety_previoussurgeries_MRIrefnote' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_MRIsafety_previoussurgeries_MRIrefnote' and answer.exists()) %}{% if currentItem.answer.exists() %}Previous surgeries: {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_patientsafety_group').exists() %}
Patient Safety Screening
Select where applicable
{% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_patientsafety_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_section').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_section') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_restingHR' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_restingHR' and answer.exists()) %}{% if currentItem.answer.exists() %}What is the patient's current resting heart rate (bpm)? {% for answer in currentItem.answer %}{{ answer.value.ofType(integer) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_known_contraindications_Nitro' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_known_contraindications_Nitro' and answer.exists()) %}{% if currentItem.answer.exists() %}Known contraindications to Nitroglycerin: (e.g., allergy, on PDE inhibitor such as Viagra® or Cialis®) {% for answer in currentItem.answer %}{% if answer.value = 'No' %}No{% endif %}{% if answer.value = 'Yes' %}Yes{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_on_betaBlockers' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_on_betaBlockers' and answer.exists()) %}{% if currentItem.answer.exists() %}Is the patient currently on beta-blockers? {% for answer in currentItem.answer %}{% if answer.value = 'No' %}No{% endif %}{% if answer.value = 'Yes' %}Yes{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_betaBlocker_concerns' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_betaBlocker_concerns' and answer.exists()) %}{% if currentItem.answer.exists() %}Concerns for beta-blockers use: {% for answer in currentItem.answer %}{% if answer.value = 'Severe/critical aortic stenosis' %}Severe/critical aortic stenosis{% endif %}{% if answer.value = 'Severe symptomatic aortic insufficiency' %}Severe symptomatic aortic insufficiency{% endif %}{% if answer.value = 'Decompensated congestive heart failure' %}Decompensated congestive heart failure{% endif %}{% if answer.value = 'Allergy to Beta-blockers' %}Allergy to Beta-blockers{% endif %}{% if answer.value = 'Prior hospitalization for lung disease' %}Prior hospitalization for lung disease{% endif %}{% if answer.value = 'Active bronchospasm' %}Active bronchospasm{% endif %}{% if answer.value = '2nd or 3rd degree heart block, or 1st degree with PR>0.42s' %}2nd or 3rd degree heart block, or 1st degree with PR>0.42s{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_betaBlockerRx' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_cardiac_betaBlockerRx' and answer.exists()) %}{% if currentItem.answer.exists() %}Will the patient be prescribed a beta-blocker? {% for answer in currentItem.answer %}{% if answer.value = 'No' %}No{% endif %}{% if answer.value = 'Yes' %}Yes{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_renal' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_renal' and answer.exists()) %}{% if currentItem.answer.exists() %}Renal Assessment Questions: {% for answer in currentItem.answer %}{% if answer.value.code = '21283' %}No known kidney issues{% endif %}{% if answer.value.code = '21316' %}Patient has impaired renal function or a history of renal transplant{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_recentegfr').exists() %}Recent (within 6 months) estimated Glomerular Filtration Rate (eGFR): {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_recentegfr') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_eGFR_result' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_eGFR_result' and answer.exists()) %}{% if currentItem.answer.exists() %}eGFR result: {% for answer in currentItem.answer %}{{ answer.value.ofType(integer) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_eGFR_date' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_eGFR_date' and answer.exists()) %}{% if currentItem.answer.exists() %}eGFR date: {% for answer in currentItem.answer %}{{ answer.value.ofType(date) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_hasDiabetes' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_hasDiabetes' and answer.exists()) %}{% if currentItem.answer.exists() %}Has diabetes: {% for answer in currentItem.answer %}{% if answer.value.code = '21286' %}Has diabetes{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_dialysis').exists() %}On dialysis: {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_dialysis') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_onDialysis' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_onDialysis' and answer.exists()) %}{% if currentItem.answer.exists() %}On dialysis: {% for answer in currentItem.answer %}{% if answer.value.code = '21287' %}On dialysis{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_contrastguidance').exists() %}Guidance on Contrast {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_contrastguidance') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_contrastguidance_question' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_contrastguidance_question' and answer.exists()) %}{% if currentItem.answer.exists() %}Guidance on Contrast Associated Acute Kidney Injury {% for answer in currentItem.answer %}{% if answer.value = 'Hide' %}Hide{% endif %}{% if answer.value = 'Show' %}Show{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_knownhypersensitivity' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_knownhypersensitivity' and answer.exists()) %}{% if currentItem.answer.exists() %}Known hypersensitivity to contrast agents: {% for answer in currentItem.answer %}{% if answer.value = 'Yes' %}Yes{% endif %}{% if answer.value = 'No' %}No{% endif %}{% if answer.value = 'Unknown' %}Unknown{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_currentlypregnant' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_currentlypregnant' and answer.exists()) %}{% if currentItem.answer.exists() %}Currently Pregnant {% for answer in currentItem.answer %}{% if answer.value.code = '21261' %}Currently Pregnant{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_currentlypregnant_sub').exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_currentlypregnant_sub') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_estimateddelivery' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_estimateddelivery' and answer.exists()) %}{% if currentItem.answer.exists() %}Estimated Date of Delivery: {% for answer in currentItem.answer %}{{ answer.value.ofType(date) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_lastmenstrualdate' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_lastmenstrualdate' and answer.exists()) %}{% if currentItem.answer.exists() %}Last Menstrual Period: {% for answer in currentItem.answer %}{{ answer.value.ofType(date) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_breastfeeding' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_breastfeeding' and answer.exists()) %}{% if currentItem.answer.exists() %}Currently breastfeeding {% for answer in currentItem.answer %}{% if answer.value.code = '21293' %}Currently breastfeeding{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_reliable' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_reliable' and answer.exists()) %}{% if currentItem.answer.exists() %}Patient cannot provide reliable medical history or provide consent to contrast injections (where applicable) {% for answer in currentItem.answer %}{% if answer.value = 'Patient cannot provide reliable medical history or provide consent to contrast injections (where applicable)' %}Patient cannot provide reliable medical history or provide consent to contrast injections (where applicable){% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility' and answer.exists()) %}{% if currentItem.answer.exists() %}Accessibility concerns or disability: {% for answer in currentItem.answer %}{% if answer.value = 'Accessibility concerns or disability' %}Accessibility concerns or disability{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility_specify' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility_specify' and answer.exists()) %}{% if currentItem.answer.exists() %} {% for answer in currentItem.answer %}{% if answer.value.code = '21270' %}Falls risk{% endif %}{% if answer.value.code = '21272' %}Patient requires lift{% endif %}{% if answer.value.code = '21274' %}Wheelchair{% endif %}{% if answer.value.code = '21271' %}Hearing impaired{% endif %}{% if answer.value.code = 'OTH' %}Other{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}, {% else %}and{% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility_specify_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_accessibility_specify_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_claustrophobia' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_claustrophobia' and answer.exists()) %}{% if currentItem.answer.exists() %}Claustrophobia {% for answer in currentItem.answer %}{% if answer.value.code = '21294' %}Claustrophobia{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_anesthesia' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_anesthesia' and answer.exists()) %}{% if currentItem.answer.exists() %}Require general anesthesia {% for answer in currentItem.answer %}{% if answer.value.code = '21295' %}Require general anesthesia{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_piccporta' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_piccporta' and answer.exists()) %}{% if currentItem.answer.exists() %}Existing vascular access: {% for answer in currentItem.answer %}{% if answer.value.code = '21383' %}Existing PICC line{% endif %}{% if answer.value.code = '21384' %}Existing Port-a-Cath{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_patientsafety_requiresedation_rationale' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_patientsafety_requiresedation_rationale' and answer.exists()) %}{% if currentItem.answer.exists() %}Rationale: {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height').exists() %}Patient Weight and Height {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_units' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_units' and answer.exists()) %}{% if currentItem.answer.exists() %}Units: {% for answer in currentItem.answer %}{% if answer.value = 'Imperial (ft.in/lbs)' %}Imperial (ft.in/lbs){% endif %}{% if answer.value = 'Metric (cm/kgs)' %}Metric (cm/kgs){% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_group').exists() %}Imperial height and weight required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_lb' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_lb' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (lbs): {% for answer in currentItem.answer %}{{ answer.value.ofType(integer) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_ft' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_ft' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (ft): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_in' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_in' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (in): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_req').exists() %}Imperial weight required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_req') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_lb' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_lb' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (lbs): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_ft' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_ft' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (ft): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_in' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_in' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (in): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired').exists() %}Imperial not required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_lb' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_lb' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (lbs): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_ft' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_ft' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (ft): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_in' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_notrequired_in' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (in): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric').exists() %}Metric height and weight required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric_kg' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric_kg' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (kgs): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric_cm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_required_metric_cm' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (cm): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_required_metric').exists() %}Metric weight required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_required_metric') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_required_metric_kg' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_required_metric_kg' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (kgs): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_required_metric_cm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_required_metric_cm' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (cm): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric').exists() %}Metric not required {% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric_kg' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric_kg' and answer.exists()) %}{% if currentItem.answer.exists() %}Weight (kgs): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric_cm' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_notrequired_metric_cm' and answer.exists()) %}{% if currentItem.answer.exists() %}Height (cm): {% for answer in currentItem.answer %}{{ answer.value.ofType(decimal) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_weight_height_date' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_weight_height_date' and answer.exists()) %}{% if currentItem.answer.exists() %}Date of Weight/Height: {% for answer in currentItem.answer %}{{ answer.value.ofType(date) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'medicalImaging_scheduling_').exists() %}Scheduling {% for currentItem in QuestionnaireResponse.item.where(linkId = 'medicalImaging_scheduling_') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'medicalImaging_scheduling' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_scheduling' and answer.exists()) %}{% if currentItem.answer.exists() %}Request specific appointment date or time interval based on: {% for answer in currentItem.answer %}{% if answer.value = 'Clinical Reasons' %}Clinical Reasons{% endif %}{% if answer.value = 'Other Considerations' %}Other Considerations{% endif %}{% if forloop.last.not() %}{% if forloop.nextitem %}; {% else %}; {% endif %}{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons_other' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons_other' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Timeframe: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons' and answer.exists()) %}{% if currentItem.answer.exists() %}Clinical Reasons: {% for answer in currentItem.answer %}{% if answer.value = 'Timed follow-up (eg,. 6 months interval study)' %}Timed follow-up (eg,. 6 months interval study){% endif %}{% if answer.value = 'Procedural (eg., pre/post op)' %}Procedural (eg., pre/post op){% endif %}{% if answer.value = 'Patient navigation (eg., Before a specialist appointment) ' %}Patient navigation (eg., Before a specialist appointment) {% endif %}{% if answer.value = 'Other clinical reasons' %}Other clinical reasons{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons_rationale' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_scheduling_clinicalreasons_rationale' and answer.exists()) %}{% if currentItem.answer.exists() %}Specify Rationale: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'medicalImaging_scheduling_nonclinical' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'medicalImaging_scheduling_nonclinical' and answer.exists()) %}{% if currentItem.answer.exists() %}Non-Clinical Considerations: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'pref_consultant_group').exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'pref_consultant_group') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'preferredconsultlocation_header').exists() %}Preferred Consultant or Location {% for currentItem in currentItem.item.where(linkId = 'preferredconsultlocation_header') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'preferredconsultlocation_selector' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'preferredconsultlocation_selector' and answer.exists()) %}{% if currentItem.answer.exists() %}Preferred consultant or location {% for answer in currentItem.answer %}{% if answer.value = 'Preferred consultant or location' %}Preferred consultant or location{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'preferredconsultlocation_willingtotravel' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'preferredconsultlocation_willingtotravel' and answer.exists()) %}{% if currentItem.answer.exists() %}Patient willing to travel for shorter wait time {% for answer in currentItem.answer %}{% if answer.value = 'Patient willing to travel for shorter wait time' %}Patient willing to travel for shorter wait time{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'preferredconsultlocation_otherconsiderations' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'preferredconsultlocation_otherconsiderations' and answer.exists()) %}{% if currentItem.answer.exists() %}Other considerations: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'supportingDocumentation_header').exists() %}Supporting Documentation {% for currentItem in QuestionnaireResponse.item.where(linkId = 'supportingDocumentation_header') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'supportingDocumentation_relevant_imaging' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'supportingDocumentation_relevant_imaging' and answer.exists()) %}{% if currentItem.answer.exists() %}Previous Relevant Imaging (if applicable) {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'supportingDocumentation_attachment' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'supportingDocumentation_attachment' and answer.exists()) %}{% if currentItem.answer.exists() %}Add attachments {% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = '657300800304' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = '657300800304' and answer.exists()) %}{% if currentItem.answer.exists() %}Personal Health Information that is medically relevant has not been disclosed at the request of the patient. {% for answer in currentItem.answer %}{% if answer.value = 'Personal Health Information that is medically relevant has not been disclosed at the request of the patient.' %}Personal Health Information that is medically relevant has not been disclosed at the request of the patient.{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = '602618746069').exists() %}Referrer's Information {% for currentItem in QuestionnaireResponse.item.where(linkId = '602618746069') %}{% capture childItems %}{% if currentItem.item.where(linkId = 'referrer_sitename' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_sitename' and answer.exists()) %}{% if currentItem.answer.exists() %}Site Name: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_address_line1' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_address_line1' and answer.exists()) %}{% if currentItem.answer.exists() %}Address (Line 1): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_address_line2' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_address_line2' and answer.exists()) %}{% if currentItem.answer.exists() %}Address (Line 2): {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_address_city' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_address_city' and answer.exists()) %}{% if currentItem.answer.exists() %}City: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_address_province' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_address_province' and answer.exists()) %}{% if currentItem.answer.exists() %}Province: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_address_postalcode' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_address_postalcode' and answer.exists()) %}{% if currentItem.answer.exists() %}Postal Code: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_phone' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_phone' and answer.exists()) %}{% if currentItem.answer.exists() %}Phone #: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_fax' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_fax' and answer.exists()) %}{% if currentItem.answer.exists() %}Fax #: {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_billing' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_billing' and answer.exists()) %}{% if currentItem.answer.exists() %}Billing Number: {% for answer in currentItem.answer %}{{ answer.value.ofType(integer) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_professionalid' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_professionalid' and answer.exists()) %}{% if currentItem.answer.exists() %}Professional ID: {% for answer in currentItem.answer %}{{ answer.value.ofType(integer) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_signature' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_signature' and answer.exists()) %}{% if currentItem.answer.exists() %}Signed: {% for answer in currentItem.answer %}{{ answer.value }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% if currentItem.item.where(linkId = 'referrer_role' and answer.exists()).exists() %}{% for currentItem in currentItem.item.where(linkId = 'referrer_role' and answer.exists()) %}{% if currentItem.answer.exists() %}Role: {% for answer in currentItem.answer %}{% if answer.value.code = '309398001' %}Allied Health Professional{% endif %}{% if answer.value.code = '21276' %}Family Physician{% endif %}{% if answer.value.code = '449161006' %}Physician Assistant{% endif %}{% if answer.value.code = '398130009' %}Medical Student{% endif %}{% if answer.value.code = '106292003' %}Nurse{% endif %}{% if answer.value.code = '224571005' %}Nurse Practitioner{% endif %}{% if answer.value.code = '21281' %}Resident{% endif %}{% if answer.value.code = '21282' %}Specialist{% endif %}{% if answer.value.code = '21402' %}Other{% endif %}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}{% endfor %}$SEP${% endif %}{% if QuestionnaireResponse.item.where(linkId = 'referralService' and answer.exists()).exists() %}{% for currentItem in QuestionnaireResponse.item.where(linkId = 'referralService' and answer.exists()) %}{% if currentItem.answer.exists() %}referralService {% for answer in currentItem.answer %}{{ answer.value.extension('').extension('').value.ofType(string) }}{% endfor %}{% endif %}{% endfor %}$SEP${% endif %}{% endcapture %}{% assign itemList = childItems || remove_last: '$SEP$' || split: '$SEP$' %}{% for listItem in itemList %}{{ listItem }}{% if forloop.last.not() %}{% if forloop.nextitem %} {% else %} {% endif %}{% endif %}{% endfor %}