# FHIR Condition 標準確立工作小組期末報告-李睿榆 組員: 109316104 林妤潔 109316110 陳奕翔 109316112 李睿榆 109316152 黃云 # 報告主題:修改Condition症狀步驟介紹 以失眠修改為頭痛為例 ## 以下是FHIR Condition 20種常見的問題狀況和SNOMED CT 的代碼: 1.發燒 (Fever)-386661006 2.失眠 (Insomnia)-195967001 3.咳嗽 (Cough)-49727002 4.頭痛 (Headache)-25064002 5.胃痛 (Stomach ache)21522001 6.腎結石 (Kidney stones) - 90721000119101 7.氣喘 (Emphysema) - 13641004 8.愛滋病 (HIV/AIDS) - 86406008 9.慢性疼痛 (Chronic pain) - 446004 10.貧血 (Anemia) - 271737000 11.高血壓 (Hypertension) - 38341003 12.糖尿病 (Diabetes mellitus) - 73211009 13.心臟病 (Heart disease) - 49601007 14.肺炎 (Pneumonia) - 233604007 15.哮喘 (Asthma) - 195967001 16.慢性阻塞性肺病 (Chronic obstructive pulmonary disease, COPD) - 13645005 17.癲癇 (Epilepsy) - 84757009 18.骨折 (Fracture) - 125605004 19.中風 (Stroke) - 422504002 20.癌症 (Cancer) - 363346000 ### 以下是擴充表單的完整程式碼: ```<!DOCTYPE html> <html> <head> <title>FHIR Insomnia Condition</title> <script src="setting.js"></script> <script src="HTTP2024.js"></script> </head> <body> <h2>FHIR Insomnia Condition</h2> <form id="conditionForm"> <label for="patientName">Patient Name:</label> <input type="text" id="patientName" required><br><br> <label for="onsetDate">Onset Date:</label> <input type="date" id="onsetDate" required><br><br> <label for="severity">Severity:</label> <select id="severity" required> <option value="">Select Severity</option> <option value="mild">Mild</option> <option value="moderate">Moderate</option> <option value="severe">Severe</option> </select><br><br> <style> body { background-image: url('https://img-bsy.txrpic.com/preview/element/00/01/13/41/E-1134169-1BA2729CXZ.jpg?imageMogr2/quality/90/thumbnail/!800x%3E'); background-size: cover; /* 背景圖片填滿整個容器 */ } </style> <button type="button" onclick="createCondition()">Create Condition</button> </form> <script> function createCondition() { var patientName = document.getElementById('patientName').value; var condition = { resourceType: 'Condition', clinicalStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-clinical', code: 'active', display: 'Active' }], text: 'Active' }, verificationStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-ver-status', code: 'confirmed', display: 'Confirmed' }], text: 'Confirmed' }, code: { coding: [{ system: 'http://snomed.info/sct', code: '195967001',//症狀的SNOMED CT 的代碼 display: '失眠' }], text: '失眠' }, subject: { reference: 'Patient/5628',//我的病人ID display: patientName }, onsetDateTime: document.getElementById('onsetDate').value + 'T00:00:00Z', severity: { coding: [{ system: 'http://snomed.info/sct', code: getSeverityCode(), display: getSeverityText() }], text: getSeverityText() } }; var jsonStr = JSON.stringify(condition); sendHttpPost(apiURL, jsonStr, callBack); } function getSeverityCode() { var severitySelect = document.getElementById('severity'); return severitySelect.options[severitySelect.selectedIndex].value; } function getSeverityText() { var severitySelect = document.getElementById('severity'); return severitySelect.options[severitySelect.selectedIndex].text; } function callBack(ret) { alert(ret); console.log(ret); } </script> </body> </html> ``` ### 討論擴展的FHIR Condition資源在處理特定症狀時的應用,有助於更全面地記錄、管理和了解患者的健康狀況。這種精細的記錄對於提供個性化的照護和更好地了解患者需求非常重要。 ## 以下是失眠在 JavaScript 中,建立 FHIR 資源的代碼區段: code: { coding: [{ system: 'http://snomed.info/sct', code: ‘195967001 ’, // 失眠的 SNOMED CT 代碼 display: 'Insomnia' // 顯示名稱 }], text: 'Insomnia' // 文本描述 }, ## 以下是頭痛在 JavaScript 中,更新建立 FHIR 資源的代碼區段: code: { coding: [{ system: 'http://snomed.info/sct', code: '25064002', // 修改為發燒的 SNOMED CT 代碼 display: '頭痛' // 更新顯示名稱 }], text: '頭痛' // 更新文本描述 }, # 以下是修改擴充表單的完整步驟: ## 步驟一:先從建立病人的頁面創建自己的病人ID ### 擴充表單建立病人的頁面 可填寫病人的基本資料並得到病人各自的ID ![image](https://hackmd.io/_uploads/rkNJ89wup.png) ### 成功上傳至FHIR Condition Server 的畫面 可看到我自己的病人ID為5628 ![image](https://hackmd.io/_uploads/HJ9orcvua.png) ## 步驟二:根據擴充表單程式碼修改之步驟如下: ### 將51至58行的code修改為「頭痛」的SNOMED CT代碼,display、text修改為「頭痛」 ![image](https://hackmd.io/_uploads/B18489vda.png) ## 步驟三:測試表單 ### 填寫表單並選擇適當的病人姓名、起始日期和嚴重程度。 ![image](https://hackmd.io/_uploads/SJ8eu5DOa.png) ### 上傳成功至FHIR Condition Server的畫面 可以看到病人為reference到李睿榆病人上 病人ID為5628 ![image](https://hackmd.io/_uploads/B1EfOcPOp.png)