123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743 |
- <?xml version="1.0" encoding="utf-8"?>
- <xsl:stylesheet version="2.0" xmlns:lxslt="http://xml.apache.org/xslt"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema"
- xmlns:n3="http://www.w3.org/1999/xhtml" xmlns:n1="urn:hl7-org:v3" xmlns:n2="urn:hl7-org:v3/meta/voc" xmlns:voc="urn:hl7-org:v3/voc" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
- <xsl:variable name="title">
- <xsl:choose>
- <xsl:when test="/n1:ClinicalDocument/n1:title">
- <xsl:value-of select="/n1:ClinicalDocument/n1:title"/>
- </xsl:when>
- <xsl:otherwise>Clinical Document</xsl:otherwise>
- </xsl:choose>
- </xsl:variable>
- <xsl:template match="/">
- <html lang="ko" xmlns="http://www.w3.org/1999/xhtml" xmlns:cda="urn:hl7-org:cda" xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance">
- <head>
- <meta http-equiv="X-UA-Compatible" content="IE=edge" charset="utf-8"/>
- <meta name="viewport" content="width=device-width"/>
- <title>
- <xsl:value-of select="$title"/>
- </title>
- <style>
- html,body { margin: 0; padding: 0; width: 100%; height: 100%;
- -ms-user-select: none;
- -moz-user-select: -moz-none;
- -khtml-user-select: none;
- -webkit-user-select: none;
- user-select: none; }
- img { border: 0; vertical-align: middle; }
- a { text-decoration: none; }
- ol,ul,li { margin: 0; padding: 0; list-style: none; }
- .container { position: relative; margin: 0 auto; width: 90%; max-width: 1200px; overflow: hidden; }
- .title { font-size: 17px; font-weight: bold; }
- .header .container{ border-bottom: 1px solid black; }
- .header .title { float: left; margin: 0 0 15px 0; font-size: 51px; }
- .header .title { float: left; margin: 0 0 15px 0; font-size: 42px; }
- .header .date { position: absolute; right: 0; bottom: 15px; font-size: 13px; }
- .request { padding: 20px 0 40px 0; }
- .request .left { float: left; width: 50%; }
- .request .right { float: left; width: 50%; }
- .request .title { float: left; width: 160px; height: 90px; overflow: hidden; }
- .request .content { height: 90px; overflow: hidden; }
- .request .content p { margin: 0 0 14px 0; }
- .patient { padding-bottom: 40px; }
- .patient .title { padding-bottom: 11px; }
- .patient table { width: 100%; border-top: 1px solid black; border-spacing: 0; text-align: left; font-size: 13px; table-layout:fixed; word-break:break-all; }
- .patient table th { padding: 13px 11px; border-bottom: 1px solid #a9a9a9; background-color: #f2f2f2; table-layout:fixed; word-break:break-all; }
- .patient table td { padding: 13px 11px; border-bottom: 1px solid #a9a9a9; table-layout:fixed; word-break:break-all; }
- .detail { padding-bottom: 40px; }
- .detail .top { padding-bottom: 10px; border-bottom: 1px solid black; overflow: hidden; }
- .detail .top .title { float: left; }
- .detail .top .all-hide-show { float: right; font-size: 14px; }
- .all-hide-show-button { cursor: pointer; }
- .detail .top .all-hide-show-button input { display: none; }
- .detail .top .all-hide-show-button .icon-show { display: none; }
- .detail .top .all-hide-show-button.active .icon-hide { display: none; }
- .detail .top .all-hide-show-button.active .icon-show { display: inline; }
- .detail .section { display: block; margin-top: 19px; }
- .detail .section input { display: none; }
- .detail .section .section-title { background-color: #cedbee; cursor: pointer; }
- .detail .section .section-title .padding { padding: 15px 23px; font-size: 14px; }
- .detail .section .section-title .icon-show { display: none; }
- .detail .section .content { display: none; background-color: #f3f6fd; overflow: hidden; width: 100%; }
- .detail .section .content .padding { padding: 15px 23px; font-size: 14px; }
- .detail .section .content .title { padding: 20px 0 0 0; }
- .detail .section .content p { margin: 0 0 5px 0; }
- .detail .section .content table { margin: 9px 0 20px 0; width: 100%; border: 1px solid #8ea6cc; border-bottom: 0; border-spacing: 0; text-align: left; font-size: 13px; table-layout:fixed; }
- .detail .section .content table th { padding: 9px 20px; background-color: #afcbfa; }
- .detail .section .content table td { padding: 9px 20px; border-bottom: 1px solid #d7dde9; background-color: white; }
- .detail .section .content table tr:last-child td { border-bottom: 1px solid #8ea6cc; }
- .detail .section .content table pre { white-space: pre-wrap; }
- .detail .section.show-content .content { display: block; }
- .detail .section.show-content .icon-hide { display: none; }
- .detail .section.show-content .icon-show { display: inline; }
- .title-icon-bar { border: 1px solid #000; height: 15px; width: 0px; float: left; margin-top: 5px; margin-right: 5px; }
- </style>
- </head>
- <body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" onload="all_show(this)">
- <xsl:apply-templates select="n1:ClinicalDocument"/>
- </body>
- </html>
- </xsl:template>
- <xsl:template match="n1:ClinicalDocument">
- <div class="header">
- <div class="container">
- <xsl:if test="/n1:ClinicalDocument/n1:code/@code!='57016-8'">
- <h1 class="title">
- <xsl:value-of select="$title"/>
- </h1>
- </xsl:if>
- <xsl:if test="/n1:ClinicalDocument/n1:code/@code='57016-8'">
- <h1 class="title2">
- <xsl:value-of select="$title"/>
- </h1>
- </xsl:if>
- <div class="date">
- 작성일 :
- <xsl:call-template name="getDate2">
- <xsl:with-param name="date" select="/n1:ClinicalDocument/n1:effectiveTime"/>
- </xsl:call-template>
- </div>
- </div>
- </div>
- <xsl:variable name="sendingOrgType">
- <xsl:choose>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='57133-1'">
- 의뢰병원
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='11488-4'">
- 회신병원
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='18761-7'">
- 회송병원
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='34133-9'">
- 작성병원정보
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='57016-8'">
- 작성병원정보
- </xsl:when>
- </xsl:choose>
- </xsl:variable>
- <div class="request">
- <div class="container">
- <div class="left">
- <div class="title">
- <div class="title-icon-bar"></div>
- <xsl:value-of select="$sendingOrgType"/>
- </div>
- <div class="content">
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:representedOrganization/n1:asOrganizationPartOf/n1:wholeOrganization/n1:name"/>
- <xsl:text xml:space="preserve"> </xsl:text>
- /
- <xsl:text xml:space="preserve"> </xsl:text>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:representedOrganization/n1:name"/>
- </p>
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:assignedPerson/n1:name/n1:family"/>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:assignedPerson/n1:name/n1:given"/>
- </p>
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:telecom/@value"/>
- </p>
- </div>
- </div>
- <xsl:if test="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:receivedOrganization/n1:asOrganizationPartOf/n1:wholeOrganization/n1:name !=''">
- <div class="right">
- <div class="title">
- <div class="title-icon-bar"></div>
- 협력병원
- </div>
- <div class="content">
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:receivedOrganization/n1:asOrganizationPartOf/n1:wholeOrganization/n1:name"/>
- <xsl:text xml:space="preserve"> </xsl:text>
- /
- <xsl:text xml:space="preserve"> </xsl:text>
- <xsl:value-of select="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:receivedOrganization/n1:name"/>
- </p>
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:informationRecipient/n1:name/n1:family"/>
- <xsl:value-of select="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:informationRecipient/n1:name/n1:given"/>
- </p>
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:informationRecipient/n1:intendedRecipient/n1:telecom/@value"/>
- </p>
- </div>
- </div>
- </xsl:if>
- </div>
- </div>
- <div class="patient">
- <div class="container">
- <div class="title">
- <div class="title-icon-bar"></div>
- 환자정보
- </div>
- <table>
- <colgroup>
- <col style="width:80px"/>
- <col style="width:auto"/>
- <col style="width:80px"/>
- <col style="width:auto"/>
- <col style="width:80px"/>
- <col style="width:auto"/>
- </colgroup>
- <tr>
- <th>성명</th>
- <td>
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:patient/n1:name/n1:family"/>
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:patient/n1:name/n1:given"/>
- </td>
- <th>생년월일</th>
- <td>
- <xsl:call-template name="getDate2">
- <xsl:with-param name="date" select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:patient/n1:birthTime"/>
- </xsl:call-template>
- </td>
- <th>성별</th>
- <td>
- <xsl:variable name='sex' select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:patient/n1:administrativeGenderCode/@code"/>
- <xsl:if test='$sex="M"'>남</xsl:if>
- <xsl:if test='$sex="F"'>여</xsl:if>
- <xsl:if test='$sex="O"'>기타</xsl:if>
- <xsl:if test='$sex="U"'>알수없음</xsl:if>
- </td>
- </tr>
- <tr>
- <th>주소</th>
- <td colspan="3">
- <xsl:if test="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:streetAddressLine !=''">
- <xsl:text xml:space="preserve"> </xsl:text>
- </xsl:if>
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:streetAddressLine"/>
- <xsl:if test="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:additionalLocator !=''">
- <xsl:text xml:space="preserve"> </xsl:text>
- </xsl:if>
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:additionalLocator"/>
- <xsl:if test="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:postalCode !=''">
- <xsl:text xml:space="preserve"> </xsl:text>
- (
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:addr/n1:postalCode"/>
- )
- </xsl:if>
- </td>
- <th>전화번호</th>
- <td>
- <xsl:value-of select="/n1:ClinicalDocument/n1:recordTarget/n1:patientRole/n1:telecom/@value"/>
- </td>
- </tr>
- <tr>
- <th>진료일</th>
- <td>
- <xsl:call-template name="getDate2">
- <xsl:with-param name="date" select="/n1:ClinicalDocument/n1:effectiveTime"/>
- </xsl:call-template>
- </td>
- <th>진료과</th>
- <td>
- <xsl:if test="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:representedOrganization/n1:asOrganizationPartOf/n1:wholeOrganization/n1:name != ''">
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:representedOrganization/n1:name"/>
- </xsl:if>
- </td>
- <th>진료의</th>
- <td>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:assignedPerson/n1:name/n1:family"/>
- <xsl:value-of select="/n1:ClinicalDocument/n1:author/n1:assignedAuthor/n1:assignedPerson/n1:name/n1:given"/>
- </td>
- </tr>
- </table>
- </div>
- </div>
- <div class="detail">
- <div class="container">
- <div class="top">
- <div class="title">
- <div class="title-icon-bar"></div>
- 상세정보
- </div>
- <div class="all-hide-show">
- <!--<label class="all-hide-show-button" id="all-hide-show-button">
- <input type="checkbox" value="1" onclick="all_show(this)" />
- <span id="all-hide-show-text">펼쳐보기</span>
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- </label>-->
- </div>
- </div>
- <xsl:if test="/n1:ClinicalDocument/n1:code/@code='57016-8'">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 동의서내용
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='57017-6']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:if test="/n1:ClinicalDocument/n1:code/@code!='57016-8'">
- <xsl:if test="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='42349-1']/n1:section/n1:text !=''">
- <xsl:variable name="reasonForReferralTitle">
- <xsl:choose>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='57133-1'">
- 의뢰사유
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='11488-4'">
- 회신사유
- </xsl:when>
- <xsl:when test="/n1:ClinicalDocument/n1:code/@code='18761-7'">
- 회송사유
- </xsl:when>
- </xsl:choose>
- </xsl:variable>
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 의뢰사유
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='42349-1']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:if test="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='10164-2']/n1:section/n1:text !=''">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 과거병력
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='10164-2']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:if test="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='51848-0']/n1:section/n1:text !=''">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 소견 및 주의사항
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:value-of select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='51848-0']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="diagnosisCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='11450-4']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$diagnosisCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 진단명(
- <xsl:value-of select="$diagnosisCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='11450-4']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="medicationCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='10160-0']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$medicationCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 투약오더(
- <xsl:value-of select="$medicationCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='10160-0']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="admissionMedicationCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='42346-7']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$admissionMedicationCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 입원투약내역(
- <xsl:value-of select="$admissionMedicationCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='42346-7']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="labResultCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='30954-2']/n1:section/n1:text/n1:list/n1:item)"/>
- <xsl:if test="$labResultCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 검사결과(
- <xsl:value-of select="$labResultCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='30954-2']/n1:section/n1:text/n1:list"/>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="procedureCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='47519-4']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$procedureCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 수술내역(
- <xsl:value-of select="$procedureCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='47519-4']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="immunizationCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='11369-6']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$immunizationCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 예방접종내역(
- <xsl:value-of select="$immunizationCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='11369-6']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="allergyCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='48765-2']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$allergyCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 알러지 및 부작용(
- <xsl:value-of select="$allergyCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='48765-2']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="smokeCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='29762-2']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$smokeCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 흡연상태(
- <xsl:value-of select="$smokeCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='29762-2']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="infectionCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='56838-6']/n1:section/n1:text/n1:table)"/>
- <xsl:if test="$infectionCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 법정 전염성 감염병(
- <xsl:value-of select="$infectionCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='56838-6']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="planCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='18776-5']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$planCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 예약관련 정보(
- <xsl:value-of select="$planCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='18776-5']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- <xsl:variable name="vitalSignCnt" select="count(/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='8716-3']/n1:section/n1:text/n1:table/n1:tbody/n1:tr)"/>
- <xsl:if test="$vitalSignCnt > 0">
- <label class="section show-content">
- <div class="section-title" onclick="hide_show(this)">
- <div class="padding">
- <span class="icon-hide">▶</span>
- <span class="icon-show">▼</span>
- 생체정보(
- <xsl:value-of select="$vitalSignCnt"/>
- )
- </div>
- </div>
- <div class="content">
- <div class="padding">
- <p>
- <xsl:apply-templates select="/n1:ClinicalDocument/n1:component/n1:structuredBody/n1:component[n1:section/n1:code/@code='8716-3']/n1:section/n1:text"/>
- </p>
- </div>
- </div>
- </label>
- </xsl:if>
- </xsl:if>
- </div>
- </div>
- </xsl:template>
- <xsl:template name="getDate1">
- <xsl:param name="date"/>
- <xsl:choose>
- <xsl:when test="$date/@value">
- <xsl:value-of select="concat(substring($date/@value,1,4),'.',substring($date/@value,5,2),'.',substring($date/@value,7,2),'')"/>
- <xsl:text> </xsl:text>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$date"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
- <xsl:template name="getDate2">
- <xsl:param name="date"/>
- <xsl:choose>
- <xsl:when test="$date/@value">
- <xsl:value-of select="concat(substring($date/@value,1,4),'년 ',substring($date/@value,5,2),'월 ',substring($date/@value,7,2),'일')"/>
- <xsl:text> </xsl:text>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$date"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
- <xsl:template name="getDate3">
- <xsl:param name="date"/>
- <xsl:choose>
- <xsl:when test="$date">
- <xsl:if test="$date !='Unknown'">
- <xsl:value-of select="concat(substring($date,1,4),'. ',substring($date,5,2),'. ',substring($date,7,2),'')"/>
- </xsl:if>
- <xsl:text> </xsl:text>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$date"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:template>
- <xsl:template match="n1:table/@*|n1:thead/@*|n1:tfoot/@*|n1:tbody/@*|n1:colgroup/@*|n1:col/@*|n1:tr/@*|n1:th/@*|n1:td/@*">
- <xsl:copy>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </xsl:copy>
- </xsl:template>
- <xsl:template match="n1:table">
- <div style="font-size: 15px;">
- <strong>
- <xsl:value-of select="substring-before(@summary,'|')" disable-output-escaping="yes"/>
- <p/>
- </strong>
- </div>
- <table class="table" width="100%">
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </table>
- </xsl:template>
- <xsl:template match="n1:thead">
- <thead>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </thead>
- </xsl:template>
- <xsl:template match="n1:tfoot">
- <tfoot>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </tfoot>
- </xsl:template>
- <xsl:template match="n1:tbody">
- <tbody>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </tbody>
- </xsl:template>
- <xsl:template match="n1:colgroup">
- <colgroup>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </colgroup>
- </xsl:template>
- <xsl:template match="n1:col">
- <col>
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </col>
- </xsl:template>
- <xsl:template match="n1:tr">
- <tr class="narr_tr">
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </tr>
- </xsl:template>
- <xsl:template match="n1:th">
- <th class="narr_th">
- <xsl:copy-of select="@*"/>
- <xsl:apply-templates/>
- </th>
- </xsl:template>
- <xsl:template match="n1:td">
- <td style="white-space:normal;">
- <xsl:choose>
- <xsl:when test="@styleCode='HIGH'">
- <xsl:copy-of select="@*"/>
- <pre style="color : red;">
- <xsl:apply-templates/>
- </pre>
- </xsl:when>
- <xsl:when test="@styleCode='LOW'">
- <xsl:copy-of select="@*"/>
- <pre style="color : blue">
- <xsl:apply-templates/>
- </pre>
- </xsl:when>
- <xsl:otherwise>
- <xsl:copy-of select="@*"/>
- <pre>
- <xsl:apply-templates/>
- </pre>
- </xsl:otherwise>
- </xsl:choose>
- </td>
- </xsl:template>
- <xsl:template match="n1:table/n1:caption">
- <span style="font-weight:bold; ">
- <xsl:apply-templates/>
- </span>
- </xsl:template>
- </xsl:stylesheet>
|