Bộ Hướng dẫn Triển khai Core FHIR cho Việt Nam
0.5.0 - Draft for Community Review
Bộ Hướng dẫn Triển khai Core FHIR cho Việt Nam - Draft for Community Review (v0.5.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions
| Draft tại thời điểm 2026-04-28 |
<StructureMap xmlns="http://hl7.org/fhir">
<id value="vn-sm-bhyt-xml3-service"/>
<language value="vi"/>
<text>
<status value="generated"/>
<div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: StructureMap vn-sm-bhyt-xml3-service</b></p><a name="vn-sm-bhyt-xml3-service"> </a><a name="hcvn-sm-bhyt-xml3-service"> </a><pre class="fml">
<b>map</b><span style="color: navy"> "</span>http://fhir.hl7.org.vn/core/StructureMap/vn-sm-bhyt-xml3-service<span style="color: navy">" = "</span>BHYTXML3ServiceLMStructureMap<span style="color: navy">"
</span><span style="color: navy">// </span><span style="color: green">Generated StructureMap scaffold for Bảng 3 DVKT và vật tư BHYT — Logical Model. Source semantics come from the logical model mapping annotations in `BHYTXML3ServiceLM.fsh` and remain aligned with the Python BHYT round-trip export adapter.</span>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-vn-core-bhyt-submission-bundle.html" title="Bundle hồ sơ thanh toán BHYT — VN Core BHYT Submission Bundle">http://fhir.hl7.org.vn/core/StructureDefinition/vn-core-bhyt-submission-bundle</a><span style="color: navy">" </span><b>alias </b>BHYTSubmissionBundle <b>as </b><b>source</b> <span style="color: navy">// </span><span style="color: green">FHIR-native source bundle profile used by the repository round-trip adapter.</span>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-bhytXml3ServiceLm.html" title="Bảng 3 DVKT và vật tư BHYT — Logical Model">http://fhir.hl7.org.vn/core/StructureDefinition/bhytXml3ServiceLm</a><span style="color: navy">" </span><b>alias </b>BHYTXML3ServiceLM <b>as </b><b>target</b> <span style="color: navy">// </span><span style="color: green">Bảng 3 DVKT và vật tư BHYT — Logical Model</span>
<span style="color: navy">// </span><span style="color: green">Full QD 3176 XML3 field catalog. Rows are derived from non-medication service, supply, device, procedure, and bed-day claim items. Generated from logical-model `^mapping` annotations. Fields still missing a field-level `^mapping.map` entry remain outside this StructureMap and are tracked in `wiki/mappings/bhyt-output-data/machine/structuremap-coverage.json`.</span>
<b>group </b>MapBHYTXML3ServiceLM<span style="color: navy">(</span><b>source</b> <span style="color: maroon">sourceBundle</span><span style="color: navy"> : </span>BHYTSubmissionBundle, <b>target</b> <span style="color: maroon">targetRow</span><span style="color: navy"> : </span>BHYTXML3ServiceLM<span style="color: navy">)</span><span style="color: navy"> {
</span> sourceBundle.entry<b> as </b><span style="color: maroon">maLkSource</span><span style="color: navy"><b> -> </b></span>targetRow.maLk <i>"maLk"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_LK - Mã liên kết hồ sơ FHIR path: VNCoreClaim.identifier[MALK].value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">sttSource</span><span style="color: navy"><b> -> </b></span>targetRow.stt <i>"stt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: STT - Số thứ tự dòng FHIR path: VNCoreClaim.item.where(category!='8').sequence</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maDichVuSource</span><span style="color: navy"><b> -> </b></span>targetRow.maDichVu <i>"maDichVu"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_DICH_VU - Mã dịch vụ kỹ thuật FHIR path: VNCoreClaim.item.where(category!='8').productOrService.coding.code | VNCoreServiceRequest.code.coding.code Mapping note: Conditionally required when MA_VAT_TU is absent or MA_NHOM is not 10.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maPtttQtSource</span><span style="color: navy"><b> -> </b></span>targetRow.maPtttQt <i>"maPtttQt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_PTTT_QT - Mã phương thức thanh toán FHIR path: VNCoreClaim.extension[paymentMethod].valueCodeableConcept.coding.code | VNCoreClaim.item.extension[paymentMethod].valueCodeableConcept.coding.code</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maVatTuSource</span><span style="color: navy"><b> -> </b></span>targetRow.maVatTu <i>"maVatTu"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_VAT_TU - Mã vật tư y tế FHIR path: VNCoreDevice.identifier[medicalDeviceItemCode].value | VNCoreClaim.item.where(category!='8').productOrService.coding.code Mapping note: Conditionally required when MA_DICH_VU is absent or MA_NHOM=10; do not collapse medical supplies into service codes when Device is available.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maNhomSource</span><span style="color: navy"><b> -> </b></span>targetRow.maNhom <i>"maNhom"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_NHOM - Mã nhóm chi phí theo QĐ 3176 FHIR path: ConceptMap/vn-cm-qd3176-cost-group-to-q697-cost-category -> VNCoreClaim.item.where(category!='8').category.coding.code Mapping note: Source code system is QD 3176 MA_NHOM. Export/import must bridge through the ConceptMap instead of assigning the QD 697 target code directly.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tenVatTuSource</span><span style="color: navy"><b> -> </b></span>targetRow.tenVatTu <i>"tenVatTu"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: TEN_VAT_TU - Tên vật tư y tế FHIR path: VNCoreDevice.deviceName.name | VNCoreClaim.item.where(category!='8').productOrService.text | display</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tenDichVuSource</span><span style="color: navy"><b> -> </b></span>targetRow.tenDichVu <i>"tenDichVu"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: TEN_DICH_VU - Tên dịch vụ kỹ thuật FHIR path: VNCoreClaim.item.where(category!='8').productOrService.text | VNCoreServiceRequest.code.text | display</span>
sourceBundle.entry<b> as </b><span style="color: maroon">donViTinhSource</span><span style="color: navy"><b> -> </b></span>targetRow.donViTinh <i>"donViTinh"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: DON_VI_TINH - Đơn vị tính FHIR path: VNCoreClaim.item.where(category!='8').quantity.unit</span>
sourceBundle.entry<b> as </b><span style="color: maroon">phamViSource</span><span style="color: navy"><b> -> </b></span>targetRow.phamVi <i>"phamVi"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: PHAM_VI - Phạm vi thanh toán FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[scope].valueCodeableConcept</span>
sourceBundle.entry<b> as </b><span style="color: maroon">soLuongSource</span><span style="color: navy"><b> -> </b></span>targetRow.soLuong <i>"soLuong"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: SO_LUONG - Số lượng FHIR path: VNCoreClaim.item.where(category!='8').quantity.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">donGiaBvSource</span><span style="color: navy"><b> -> </b></span>targetRow.donGiaBv <i>"donGiaBv"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: DON_GIA_BV - Đơn giá bệnh viện FHIR path: VNCoreClaim.item.where(category!='8').unitPrice.value | VNCoreClaim.item.extension[hospitalUnitPrice].valueMoney.value Mapping note: Hospital charge price; keep separate from the BHYT price to avoid financial round-trip loss.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">donGiaBhSource</span><span style="color: navy"><b> -> </b></span>targetRow.donGiaBh <i>"donGiaBh"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: DON_GIA_BH - Đơn giá BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[insuranceUnitPrice].valueMoney.value Mapping note: BHYT-covered unit price; do not collapse into Claim.item.unitPrice when hospital and insurance prices differ.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tyleTtDvSource</span><span style="color: navy"><b> -> </b></span>targetRow.tyleTtDv <i>"tyleTtDv"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: TYLE_TT_DV - Tỷ lệ thanh toán dịch vụ FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[servicePaymentRatio].valueDecimal</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tyleTtBhSource</span><span style="color: navy"><b> -> </b></span>targetRow.tyleTtBh <i>"tyleTtBh"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: TYLE_TT_BH - Tỷ lệ thanh toán BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[paymentRatio].valueDecimal</span>
sourceBundle.entry<b> as </b><span style="color: maroon">thanhTienBvSource</span><span style="color: navy"><b> -> </b></span>targetRow.thanhTienBv <i>"thanhTienBv"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: THANH_TIEN_BV - Thành tiền bệnh viện FHIR path: VNCoreClaim.item.where(category!='8').net.value | VNCoreClaim.item.extension[hospitalLineAmount].valueMoney.value Mapping note: Hospital line amount; keep separate from BHYT line amount.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">thanhTienBhSource</span><span style="color: navy"><b> -> </b></span>targetRow.thanhTienBh <i>"thanhTienBh"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: THANH_TIEN_BH - Thành tiền BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[insuranceLineAmount].valueMoney.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">mucHuongSource</span><span style="color: navy"><b> -> </b></span>targetRow.mucHuong <i>"mucHuong"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MUC_HUONG - Mức hưởng FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[benefitLevel].valueDecimal</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tBnttSource</span><span style="color: navy"><b> -> </b></span>targetRow.tBntt <i>"tBntt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: T_BNTT - Người bệnh tự trả FHIR path: Derived from VNCoreClaimResponse.item[serviceLine].adjudication.where(category='submitted').amount - .where(category='eligible').amount | Derived from VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='submitted').amount - .where(category='eligible').amount</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tBncctSource</span><span style="color: navy"><b> -> </b></span>targetRow.tBncct <i>"tBncct"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: T_BNCCT - Người bệnh cùng chi trả FHIR path: VNCoreClaimResponse.item[serviceLine].adjudication.where(category='copay').amount.value | VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='copay').amount.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">tBhttSource</span><span style="color: navy"><b> -> </b></span>targetRow.tBhtt <i>"tBhtt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: T_BHTT - Quỹ BHYT thanh toán FHIR path: VNCoreClaimResponse.item[serviceLine].adjudication.where(category='benefit').amount.value | VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='benefit').amount.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maKhoaSource</span><span style="color: navy"><b> -> </b></span>targetRow.maKhoa <i>"maKhoa"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_KHOA - Mã khoa FHIR path: VNCoreClaim.item.where(category!='8').extension[department].valueCodeableConcept.coding.code</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maGiuongSource</span><span style="color: navy"><b> -> </b></span>targetRow.maGiuong <i>"maGiuong"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_GIUONG - Mã giường FHIR path: VNCoreEncounter.location.location.resolve().identifier.value Mapping note: Conditionally required for bed-day MA_NHOM values 14, 15, 16.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maBacSiSource</span><span style="color: navy"><b> -> </b></span>targetRow.maBacSi <i>"maBacSi"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_BAC_SI - Mã bác sĩ FHIR path: VNCoreServiceRequest.requester.resolve().identifier.value | VNCoreProcedure.performer.actor.resolve().identifier.value | VNCorePractitioner.identifier.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">nguoiThucHienSource</span><span style="color: navy"><b> -> </b></span>targetRow.nguoiThucHien <i>"nguoiThucHien"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: NGUOI_THUC_HIEN - Người thực hiện FHIR path: VNCoreProcedure.performer.actor.resolve().identifier.value | VNCorePractitioner.identifier.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maBenhSource</span><span style="color: navy"><b> -> </b></span>targetRow.maBenh <i>"maBenh"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_BENH - Mã bệnh liên quan FHIR path: VNCoreCondition.code | VNCoreClaim.diagnosis.diagnosisCodeableConcept</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maBenhYhctSource</span><span style="color: navy"><b> -> </b></span>targetRow.maBenhYhct <i>"maBenhYhct"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_BENH_YHCT - Mã bệnh y học cổ truyền FHIR path: VNCoreClaim.diagnosis.diagnosisCodeableConcept.coding[yhct].code | VNCoreCondition.code.coding[yhct].code</span>
sourceBundle.entry<b> as </b><span style="color: maroon">ngayYlSource</span><span style="color: navy"><b> -> </b></span>targetRow.ngayYl <i>"ngayYl"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: NGAY_YL - Ngày y lệnh FHIR path: VNCoreServiceRequest.authoredOn | VNCoreProcedure.basedOn.resolve().authoredOn</span>
sourceBundle.entry<b> as </b><span style="color: maroon">ngayThYlSource</span><span style="color: navy"><b> -> </b></span>targetRow.ngayThYl <i>"ngayThYl"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: NGAY_TH_YL - Ngày thực hiện y lệnh FHIR path: VNCoreProcedure.performedDateTime | VNCoreServiceRequest.occurrenceDateTime</span>
sourceBundle.entry<b> as </b><span style="color: maroon">ngayKqSource</span><span style="color: navy"><b> -> </b></span>targetRow.ngayKq <i>"ngayKq"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: NGAY_KQ - Ngày kết quả FHIR path: VNCoreDiagnosticReport.issued | VNCoreObservationLab.effectiveDateTime Mapping note: Conditionally required except for bed-day MA_NHOM values 14, 15, 16.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maPtttSource</span><span style="color: navy"><b> -> </b></span>targetRow.maPttt <i>"maPttt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_PTTT - Mã phẫu thuật/thủ thuật FHIR path: VNCoreClaim.procedure.procedureCodeableConcept | VNCoreProcedure.code</span>
sourceBundle.entry<b> as </b><span style="color: maroon">vetThuongTpSource</span><span style="color: navy"><b> -> </b></span>targetRow.vetThuongTp <i>"vetThuongTp"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: VET_THUONG_TP - Vết thương tái phát FHIR path: VNCoreClaim.item[serviceLine].extension[recurrentWoundBenefit].valueBoolean | VNCoreExplanationOfBenefit.item[serviceLine].extension[recurrentWoundBenefit].valueBoolean Mapping note: Exporter emits literal `1` only when the line-level recurrentWoundBenefit flag is true; this is not a diagnosis recurrence code.</span>
sourceBundle.entry<b> as </b><span style="color: maroon">viTriThDvktSource</span><span style="color: navy"><b> -> </b></span>targetRow.viTriThDvkt <i>"viTriThDvkt"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: VI_TRI_TH_DVKT - Vị trí thực hiện DVKT FHIR path: VNCoreProcedure.bodySite | VNCoreServiceRequest.bodySite</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maMaySource</span><span style="color: navy"><b> -> </b></span>targetRow.maMay <i>"maMay"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_MAY - Mã máy FHIR path: VNCoreDevice.identifier.value</span>
sourceBundle.entry<b> as </b><span style="color: maroon">maHieuSpSource</span><span style="color: navy"><b> -> </b></span>targetRow.maHieuSp <i>"maHieuSp"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: MA_HIEU_SP - Mã hiệu sản phẩm FHIR path: VNCoreDevice.deviceName.name | VNCoreDevice.modelNumber</span>
sourceBundle.entry<b> as </b><span style="color: maroon">taiSuDungSource</span><span style="color: navy"><b> -> </b></span>targetRow.taiSuDung <i>"taiSuDung"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">Target field: TAI_SU_DUNG - Tái sử dụng FHIR path: VNCoreDeviceUseStatement.note | future reusable-device extension</span>
<span style="color: navy">}
</span></pre></div>
</text>
<url
value="http://fhir.hl7.org.vn/core/StructureMap/vn-sm-bhyt-xml3-service"/>
<version value="0.5.0"/>
<name value="BHYTXML3ServiceLMStructureMap"/>
<title value="Bảng 3 DVKT và vật tư BHYT — Logical Model — StructureMap"/>
<status value="draft"/>
<experimental value="false"/>
<date value="2026-04-28"/>
<publisher value="Omi HealthTech / VN Core FHIR Community Initiative"/>
<contact>
<name value="Omi HealthTech / VN Core FHIR Community Initiative"/>
<telecom>
<system value="url"/>
<value value="https://hl7.org.vn"/>
</telecom>
<telecom>
<system value="email"/>
<value value="[email protected]"/>
</telecom>
</contact>
<contact>
<name value="Omi HealthTech (OmiGroup)"/>
<telecom>
<system value="url"/>
<value value="https://omihealthtech.vn"/>
</telecom>
<telecom>
<system value="url"/>
<value value="https://omigroup.vn"/>
</telecom>
<telecom>
<system value="email"/>
<value value="[email protected]"/>
</telecom>
</contact>
<description
value="Generated StructureMap scaffold for Bảng 3 DVKT và vật tư BHYT — Logical Model. Source semantics come from the logical model mapping annotations in `BHYTXML3ServiceLM.fsh` and remain aligned with the Python BHYT round-trip export adapter."/>
<jurisdiction>
<coding>
<system value="urn:iso:std:iso:3166"/>
<code value="VN"/>
<display value="Viet Nam"/>
</coding>
</jurisdiction>
<purpose
value="Publish canonical, reviewable FHIR-to-BHYT XML mapping artifacts for XML1-XML12 without duplicating field-level mapping semantics across FSH, wiki, and export code."/>
<structure>
<url
value="http://fhir.hl7.org.vn/core/StructureDefinition/vn-core-bhyt-submission-bundle"/>
<mode value="source"/>
<alias value="BHYTSubmissionBundle"/>
<documentation
value="FHIR-native source bundle profile used by the repository round-trip adapter."/>
</structure>
<structure>
<url
value="http://fhir.hl7.org.vn/core/StructureDefinition/bhytXml3ServiceLm"/>
<mode value="target"/>
<alias value="BHYTXML3ServiceLM"/>
<documentation value="Bảng 3 DVKT và vật tư BHYT — Logical Model"/>
</structure>
<group>
<name value="MapBHYTXML3ServiceLM"/>
<typeMode value="none"/>
<documentation
value="Full QD 3176 XML3 field catalog. Rows are derived from non-medication service, supply, device, procedure, and bed-day claim items. Generated from logical-model `^mapping` annotations. Fields still missing a field-level `^mapping.map` entry remain outside this StructureMap and are tracked in `wiki/mappings/bhyt-output-data/machine/structuremap-coverage.json`."/>
<input>
<name value="sourceBundle"/>
<type value="BHYTSubmissionBundle"/>
<mode value="source"/>
<documentation value="VN Core BHYT submission bundle."/>
</input>
<input>
<name value="targetRow"/>
<type value="BHYTXML3ServiceLM"/>
<mode value="target"/>
<documentation value="Bảng 3 DVKT và vật tư BHYT — Logical Model"/>
</input>
<rule>
<name value="maLk"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maLkSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maLk"/>
</target>
<documentation
value="Target field: MA_LK - Mã liên kết hồ sơ FHIR path: VNCoreClaim.identifier[MALK].value"/>
</rule>
<rule>
<name value="stt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="sttSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="stt"/>
</target>
<documentation
value="Target field: STT - Số thứ tự dòng FHIR path: VNCoreClaim.item.where(category!='8').sequence"/>
</rule>
<rule>
<name value="maDichVu"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maDichVuSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maDichVu"/>
</target>
<documentation
value="Target field: MA_DICH_VU - Mã dịch vụ kỹ thuật FHIR path: VNCoreClaim.item.where(category!='8').productOrService.coding.code | VNCoreServiceRequest.code.coding.code Mapping note: Conditionally required when MA_VAT_TU is absent or MA_NHOM is not 10."/>
</rule>
<rule>
<name value="maPtttQt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maPtttQtSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maPtttQt"/>
</target>
<documentation
value="Target field: MA_PTTT_QT - Mã phương thức thanh toán FHIR path: VNCoreClaim.extension[paymentMethod].valueCodeableConcept.coding.code | VNCoreClaim.item.extension[paymentMethod].valueCodeableConcept.coding.code"/>
</rule>
<rule>
<name value="maVatTu"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maVatTuSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maVatTu"/>
</target>
<documentation
value="Target field: MA_VAT_TU - Mã vật tư y tế FHIR path: VNCoreDevice.identifier[medicalDeviceItemCode].value | VNCoreClaim.item.where(category!='8').productOrService.coding.code Mapping note: Conditionally required when MA_DICH_VU is absent or MA_NHOM=10; do not collapse medical supplies into service codes when Device is available."/>
</rule>
<rule>
<name value="maNhom"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maNhomSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maNhom"/>
</target>
<documentation
value="Target field: MA_NHOM - Mã nhóm chi phí theo QĐ 3176 FHIR path: ConceptMap/vn-cm-qd3176-cost-group-to-q697-cost-category -> VNCoreClaim.item.where(category!='8').category.coding.code Mapping note: Source code system is QD 3176 MA_NHOM. Export/import must bridge through the ConceptMap instead of assigning the QD 697 target code directly."/>
</rule>
<rule>
<name value="tenVatTu"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tenVatTuSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tenVatTu"/>
</target>
<documentation
value="Target field: TEN_VAT_TU - Tên vật tư y tế FHIR path: VNCoreDevice.deviceName.name | VNCoreClaim.item.where(category!='8').productOrService.text | display"/>
</rule>
<rule>
<name value="tenDichVu"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tenDichVuSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tenDichVu"/>
</target>
<documentation
value="Target field: TEN_DICH_VU - Tên dịch vụ kỹ thuật FHIR path: VNCoreClaim.item.where(category!='8').productOrService.text | VNCoreServiceRequest.code.text | display"/>
</rule>
<rule>
<name value="donViTinh"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="donViTinhSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="donViTinh"/>
</target>
<documentation
value="Target field: DON_VI_TINH - Đơn vị tính FHIR path: VNCoreClaim.item.where(category!='8').quantity.unit"/>
</rule>
<rule>
<name value="phamVi"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="phamViSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="phamVi"/>
</target>
<documentation
value="Target field: PHAM_VI - Phạm vi thanh toán FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[scope].valueCodeableConcept"/>
</rule>
<rule>
<name value="soLuong"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="soLuongSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="soLuong"/>
</target>
<documentation
value="Target field: SO_LUONG - Số lượng FHIR path: VNCoreClaim.item.where(category!='8').quantity.value"/>
</rule>
<rule>
<name value="donGiaBv"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="donGiaBvSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="donGiaBv"/>
</target>
<documentation
value="Target field: DON_GIA_BV - Đơn giá bệnh viện FHIR path: VNCoreClaim.item.where(category!='8').unitPrice.value | VNCoreClaim.item.extension[hospitalUnitPrice].valueMoney.value Mapping note: Hospital charge price; keep separate from the BHYT price to avoid financial round-trip loss."/>
</rule>
<rule>
<name value="donGiaBh"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="donGiaBhSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="donGiaBh"/>
</target>
<documentation
value="Target field: DON_GIA_BH - Đơn giá BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[insuranceUnitPrice].valueMoney.value Mapping note: BHYT-covered unit price; do not collapse into Claim.item.unitPrice when hospital and insurance prices differ."/>
</rule>
<rule>
<name value="tyleTtDv"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tyleTtDvSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tyleTtDv"/>
</target>
<documentation
value="Target field: TYLE_TT_DV - Tỷ lệ thanh toán dịch vụ FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[servicePaymentRatio].valueDecimal"/>
</rule>
<rule>
<name value="tyleTtBh"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tyleTtBhSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tyleTtBh"/>
</target>
<documentation
value="Target field: TYLE_TT_BH - Tỷ lệ thanh toán BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[paymentRatio].valueDecimal"/>
</rule>
<rule>
<name value="thanhTienBv"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="thanhTienBvSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="thanhTienBv"/>
</target>
<documentation
value="Target field: THANH_TIEN_BV - Thành tiền bệnh viện FHIR path: VNCoreClaim.item.where(category!='8').net.value | VNCoreClaim.item.extension[hospitalLineAmount].valueMoney.value Mapping note: Hospital line amount; keep separate from BHYT line amount."/>
</rule>
<rule>
<name value="thanhTienBh"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="thanhTienBhSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="thanhTienBh"/>
</target>
<documentation
value="Target field: THANH_TIEN_BH - Thành tiền BHYT FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[insuranceLineAmount].valueMoney.value"/>
</rule>
<rule>
<name value="mucHuong"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="mucHuongSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="mucHuong"/>
</target>
<documentation
value="Target field: MUC_HUONG - Mức hưởng FHIR path: VNCoreClaim.item.where(category!='8').extension[insuranceCostInfo].extension[benefitLevel].valueDecimal"/>
</rule>
<rule>
<name value="tBntt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tBnttSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tBntt"/>
</target>
<documentation
value="Target field: T_BNTT - Người bệnh tự trả FHIR path: Derived from VNCoreClaimResponse.item[serviceLine].adjudication.where(category='submitted').amount - .where(category='eligible').amount | Derived from VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='submitted').amount - .where(category='eligible').amount"/>
</rule>
<rule>
<name value="tBncct"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tBncctSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tBncct"/>
</target>
<documentation
value="Target field: T_BNCCT - Người bệnh cùng chi trả FHIR path: VNCoreClaimResponse.item[serviceLine].adjudication.where(category='copay').amount.value | VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='copay').amount.value"/>
</rule>
<rule>
<name value="tBhtt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="tBhttSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="tBhtt"/>
</target>
<documentation
value="Target field: T_BHTT - Quỹ BHYT thanh toán FHIR path: VNCoreClaimResponse.item[serviceLine].adjudication.where(category='benefit').amount.value | VNCoreExplanationOfBenefit.item[serviceLine].adjudication.where(category='benefit').amount.value"/>
</rule>
<rule>
<name value="maKhoa"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maKhoaSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maKhoa"/>
</target>
<documentation
value="Target field: MA_KHOA - Mã khoa FHIR path: VNCoreClaim.item.where(category!='8').extension[department].valueCodeableConcept.coding.code"/>
</rule>
<rule>
<name value="maGiuong"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maGiuongSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maGiuong"/>
</target>
<documentation
value="Target field: MA_GIUONG - Mã giường FHIR path: VNCoreEncounter.location.location.resolve().identifier.value Mapping note: Conditionally required for bed-day MA_NHOM values 14, 15, 16."/>
</rule>
<rule>
<name value="maBacSi"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maBacSiSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maBacSi"/>
</target>
<documentation
value="Target field: MA_BAC_SI - Mã bác sĩ FHIR path: VNCoreServiceRequest.requester.resolve().identifier.value | VNCoreProcedure.performer.actor.resolve().identifier.value | VNCorePractitioner.identifier.value"/>
</rule>
<rule>
<name value="nguoiThucHien"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="nguoiThucHienSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="nguoiThucHien"/>
</target>
<documentation
value="Target field: NGUOI_THUC_HIEN - Người thực hiện FHIR path: VNCoreProcedure.performer.actor.resolve().identifier.value | VNCorePractitioner.identifier.value"/>
</rule>
<rule>
<name value="maBenh"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maBenhSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maBenh"/>
</target>
<documentation
value="Target field: MA_BENH - Mã bệnh liên quan FHIR path: VNCoreCondition.code | VNCoreClaim.diagnosis.diagnosisCodeableConcept"/>
</rule>
<rule>
<name value="maBenhYhct"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maBenhYhctSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maBenhYhct"/>
</target>
<documentation
value="Target field: MA_BENH_YHCT - Mã bệnh y học cổ truyền FHIR path: VNCoreClaim.diagnosis.diagnosisCodeableConcept.coding[yhct].code | VNCoreCondition.code.coding[yhct].code"/>
</rule>
<rule>
<name value="ngayYl"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="ngayYlSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="ngayYl"/>
</target>
<documentation
value="Target field: NGAY_YL - Ngày y lệnh FHIR path: VNCoreServiceRequest.authoredOn | VNCoreProcedure.basedOn.resolve().authoredOn"/>
</rule>
<rule>
<name value="ngayThYl"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="ngayThYlSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="ngayThYl"/>
</target>
<documentation
value="Target field: NGAY_TH_YL - Ngày thực hiện y lệnh FHIR path: VNCoreProcedure.performedDateTime | VNCoreServiceRequest.occurrenceDateTime"/>
</rule>
<rule>
<name value="ngayKq"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="ngayKqSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="ngayKq"/>
</target>
<documentation
value="Target field: NGAY_KQ - Ngày kết quả FHIR path: VNCoreDiagnosticReport.issued | VNCoreObservationLab.effectiveDateTime Mapping note: Conditionally required except for bed-day MA_NHOM values 14, 15, 16."/>
</rule>
<rule>
<name value="maPttt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maPtttSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maPttt"/>
</target>
<documentation
value="Target field: MA_PTTT - Mã phẫu thuật/thủ thuật FHIR path: VNCoreClaim.procedure.procedureCodeableConcept | VNCoreProcedure.code"/>
</rule>
<rule>
<name value="vetThuongTp"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="vetThuongTpSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="vetThuongTp"/>
</target>
<documentation
value="Target field: VET_THUONG_TP - Vết thương tái phát FHIR path: VNCoreClaim.item[serviceLine].extension[recurrentWoundBenefit].valueBoolean | VNCoreExplanationOfBenefit.item[serviceLine].extension[recurrentWoundBenefit].valueBoolean Mapping note: Exporter emits literal `1` only when the line-level recurrentWoundBenefit flag is true; this is not a diagnosis recurrence code."/>
</rule>
<rule>
<name value="viTriThDvkt"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="viTriThDvktSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="viTriThDvkt"/>
</target>
<documentation
value="Target field: VI_TRI_TH_DVKT - Vị trí thực hiện DVKT FHIR path: VNCoreProcedure.bodySite | VNCoreServiceRequest.bodySite"/>
</rule>
<rule>
<name value="maMay"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maMaySource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maMay"/>
</target>
<documentation
value="Target field: MA_MAY - Mã máy FHIR path: VNCoreDevice.identifier.value"/>
</rule>
<rule>
<name value="maHieuSp"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="maHieuSpSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="maHieuSp"/>
</target>
<documentation
value="Target field: MA_HIEU_SP - Mã hiệu sản phẩm FHIR path: VNCoreDevice.deviceName.name | VNCoreDevice.modelNumber"/>
</rule>
<rule>
<name value="taiSuDung"/>
<source>
<context value="sourceBundle"/>
<min value="0"/>
<max value="*"/>
<element value="entry"/>
<variable value="taiSuDungSource"/>
</source>
<target>
<context value="targetRow"/>
<contextType value="variable"/>
<element value="taiSuDung"/>
</target>
<documentation
value="Target field: TAI_SU_DUNG - Tái sử dụng FHIR path: VNCoreDeviceUseStatement.note | future reusable-device extension"/>
</rule>
</group>
</StructureMap>