Changeset 993 for ccr2ccd-xslt


Ignore:
Timestamp:
Oct 26, 2010, 10:15:50 PM (13 years ago)
Author:
George Lilly
Message:

update

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ccr2ccd-xslt/trunk/make/Nancy-ccr_qrda-M1.xsl

    r992 r993  
    775775                        </component>
    776776                    </xsl:if>
    777 <component>
    778 <section>
    779 <!--We are including only a coverage activity for Medicare here. There is also policy activity and and authorization activity that I don't think we need to report for QRDA, at least not for most reports-->
    780 <templateId root="2.16.840.1.113883.10.20.1.9"/>
    781 <!-- 48768-6 is payment sources and is fixed CQ-188,189,190-->
    782 <code code="48768-6" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="Payment Sources"/>
    783 <!--CQ-191,192-->
    784 <title>Payers</title>
    785 <!--medicare-->
    786 <entry typeCode="DRIV">
    787 <!--WVP moodCode is DEF is definition to describe the characteristics of who must be involved in an act CQ-194,195-->
    788 <act classCode="ACT" moodCode="DEF">
    789 <!--WVP coverage activity template is the 10.20.1.20 CQ-193-->
    790 <templateId root="2.16.840.1.113883.10.20.1.20"/>
    791 <!--Coverage Shall Include and Act ID CQ-196-->
    792 <!--looks like a UUID to me-->
    793 <id root="1751b180-8a54-11df-a4ee-0800200c9c66"/><!--FIX!!!???-->
    794 <!--CQ-197-198 It appears that statusCode="completed" need to follow the code code ... here and below-->
    795 
    796 <!--CQ199,200-->
    797 <code code="48768-6" codeSystem="2.16.840.1.113883.6.1" displayName="Payment sources"/>
    798 <statusCode code="completed"/>
    799 
    800 <!--A coverage activity shall contain on or more act/entryRelationship. The value for  act/entryRelationship/@typeCode shall be COMP which SHALL be  the CMS QRDA Policy Activity CQ-201, 203-->
    801 <!--It MAY contain an entryRelationship/sequenceNumber CQ-202-->
    802 <entryRelationship typeCode="COMP">
    803 <!--  for the act is event with moodCode EVN  CQ-205,206,207-->
    804 <act classCode="ACT" moodCode="EVN">
    805 <!--Policy activity is the 10.20.1.26 template CQ-205-->
    806 <templateId root="2.16.840.1.113883.10.20.1.26"/>
    807 
    808 <!-- act/id which is the group or contract number related to the insurance policy or program CQ-208-->
    809 <id root="dbbb6311-8a4d-11df-a4ee-0800200c9c66"/><!--!!!FIX-->
    810 <!--Act statusCode must be completed CQ-210-->
    811 <!--This SHOULD be present and comes from the downloadable resource S display name is in quotes AUTOPOL - "automobile" policy;EHCPOL additional insurance in addition to Medicare in this case
    812 HSAPOL "Health Spending Account";PUBLICPOL "public healthcare" which is NOT Medicare - maybe a state program for example
    813 WBCPOL is "workers compensation" CQ-211,212-->
    814 <!--<code code="PUBLICPOL" codeSystem="2.16.840.1.113883.5.4" displayName="Public Healthcare"/>-->
    815 <code code="PUBLICPOL" codeSystem="2.16.840.1.113883.5.4" displayName="Public Healthcare"/>
    816 <!--WVP performer type codes are numerous but PRF is performer representing the Payer CQ-213-->
    817 <statusCode code="completed"/>
    818 <performer typeCode="PRF">
    819 
    820 <!--performer/assignedEntity id is the payer identification and the extension comes from the downloadable resource section I insurance plan TYPE CQ-214-->
    821 <assignedEntity>
    822 <id root="2.16.840.1.113883.12.86" extension="MC"/>
    823 <!--<representedOrganization>
    824 <name>CMS</name>
    825 </representedOrganization>-->
    826 </assignedEntity>
    827 </performer>
    828 <!-- Act/participant @typeCode this represents the covered party CQ-215-->
    829 <participant typeCode="COV">
    830 <participantRole>
    831 <!--A covered party in a policy activity SHOULD contain one or more participant/participantRole/id to represent the patien's member of subscriber identifier with respect to the payer
    832 For participant/paricipantRole/id either the Social Security Number or HIC Number SHALL be submitted for Medicare patients. for SSN the ID @root SHALL be 2.16.840.1.113883.4.1 where
    833 the HIC id/@root shall be 2.16.840.1.113883.3.249.13 CQ-216"RoleCode" in the downloadable resource-->
    834 <!-- in this case theextension is the patients SSN for a medicare patient so it is the same each time for one patient-->
    835 <id root="2.16.840.1.113883.4.1" extension="@@SSN@@"/>
    836 <!--The covered party in tha policy activity SHOULD contain exactly one particpant/participantRole/code for self, family etc from the valuse set PolicyOrPrograCoverageRoleType 2.16.840.1.113883.1.11.19809 CQ-217,218-->
    837 <code code="SELF" codeSystem="2.16.840.1.113883.5.111" displayName="Self"/>
    838 </participantRole>
    839 </participant>
    840 </act>
    841 </entryRelationship>
    842 </act>
    843 </entry>
    844 </section>
    845 </component>
    846                     <xsl:if test="a:ContinuityOfCareRecord/a:Body/a:Results/a:Result">
    847                         <component>
    848                             <section>
    849                                 <templateId root="2.16.840.1.113883.10.20.1.14"/>
    850                                 <code code="30954-2" codeSystem="2.16.840.1.113883.6.1"/>
    851                                 <title>Results</title>
    852                                 <text>
    853                                     <table>
    854                                         <tbody>
    855                                             <tr>
    856                                                 <th>Test</th>
    857                                                 <th>Date</th>
    858                                                 <th>Result</th>
    859                                                 <th>Source</th>
    860                                             </tr>
    861                                             <xsl:for-each select="/a:ContinuityOfCareRecord/a:Body/a:Results/a:Result">
    862                                                 <tr>
    863                                                     <xsl:attribute name="id">
    864                                                         <xsl:value-of select="a:CCRDataObjectID"/>
    865                                                     </xsl:attribute>
    866                                                     <td>
    867                                                         <xsl:value-of select="a:Description/a:Text"/>
    868                                                     </td>
    869                                                     <td>
    870                                                         <xsl:call-template name="date:format-date">
    871                                                             <xsl:with-param name="date-time" select="a:DateTime/a:ExactDateTime"/>
    872                                                         </xsl:call-template>
    873                                                     </td>
    874                                                     <td>
    875                                                         <xsl:for-each select="a:Test[a:TestResult/a:Value!='']">
    876                                                             <div>
    877                                                                 <xsl:attribute name="id">
    878                                                                     <xsl:value-of select="a:CCRDataObjectID"/>
    879                                                                 </xsl:attribute>
    880 
    881                                                                 <xsl:value-of select="a:Description/a:Text"/>
    882                                                                 <xsl:text xml:space="preserve"> </xsl:text>
    883                                                                 <xsl:value-of select="a:TestResult/a:Value"/>
    884                                                                 <xsl:text xml:space="preserve"> </xsl:text>
    885                                                                 <xsl:value-of select="a:TestResult/a:Units/a:Unit"/>
    886                                                                 <xsl:text xml:space="preserve"> </xsl:text>
    887                                                                 <xsl:value-of select="a:Flag/a:Text"/>
    888                                                                 <br/>
    889                                                             </div>
    890                                                         </xsl:for-each>
    891                                                         <xsl:for-each select="a:Test[a:TestResult/a:Description/a:Text!='']">
    892                                                             <div>
    893                                                                 <xsl:attribute name="id">
    894                                                                     <xsl:value-of select="a:CCRDataObjectID"/>
    895                                                                 </xsl:attribute>
    896 
    897                                                                 <xsl:value-of select="a:Description/a:Text"/>
    898                                                                 <xsl:text xml:space="preserve"> </xsl:text>
    899                                                                 <xsl:value-of select="a:TestResult/a:Description/a:Text" disable-output-escaping="yes"/>
    900                                                                 <xsl:text xml:space="preserve"> </xsl:text>
    901                                                                 <xsl:value-of select="a:Flag/a:Text"/>
    902                                                                 <br/>
    903                                                             </div>
    904                                                         </xsl:for-each>
    905                                                     </td>
    906                                                     <td>
    907                                                         <xsl:call-template name="actorName">
    908                                                             <xsl:with-param name="objID" select="a:Source/a:Actor/a:ActorID"/>
    909                                                         </xsl:call-template>
    910                                                     </td>
    911                                                 </tr>
    912                                             </xsl:for-each>
    913                                         </tbody>
    914                                     </table>
    915                                 </text>
    916                                 <xsl:for-each select="/a:ContinuityOfCareRecord/a:Body/a:Results/a:Result">
    917                                     <entry typeCode="DRIV">
    918                                         <xsl:variable name="testDate" select="a:DateTime"/>
    919 
    920                                         <xsl:choose>
    921                                             <xsl:when test="count(a:Test)>1">
    922                                                 <organizer classCode="BATTERY" moodCode="EVN">
    923                                                     <templateId root="2.16.840.1.113883.10.20.1.32"/>
    924                                                     <!--Result organizer template -->
    925 
    926                                                     <!-- <id> -->
    927                                                     <xsl:call-template name="ccdID">
    928                                                         <xsl:with-param name="ccrObjectID" select="a:CCRDataObjectID"/>
    929                                                     </xsl:call-template>
    930 
    931                                                     <!-- <code> -->
    932                                                     <xsl:call-template name="ccdCodedValue">
    933                                                         <xsl:with-param name="ccrCodedDescription" select="a:Description"/>
    934                                                         <xsl:with-param name="nodeName" select="'code'"/>
    935                                                     </xsl:call-template>
    936 
    937                                                     <statusCode code="completed"/>
    938 
    939                                                     <!-- <effectiveTime> -->
    940                                                     <xsl:call-template name="ccdDateTime">
    941                                                         <xsl:with-param name="dt" select="$testDate"/>
    942                                                     </xsl:call-template>
    943 
    944                                                     <xsl:call-template name="ccdPerformer">
    945                                                         <xsl:with-param name="ccrActorReference" select="a:Source/a:Actor"/>
    946                                                     </xsl:call-template>
    947 
    948                                                     <xsl:for-each select="a:Test">
    949                                                         <xsl:call-template name="ccdObservation">
    950                                                             <xsl:with-param name="ccrTestNode" select="."/>
    951                                                             <xsl:with-param name="testDate" select="$testDate"/>
    952                                                         </xsl:call-template>
    953                                                     </xsl:for-each>
    954 
    955                                                 </organizer>
    956 
    957                                             </xsl:when>
    958                                             <xsl:otherwise>
    959                                                 <xsl:call-template name="ccdObservation">
    960                                                     <xsl:with-param name="ccrTestNode" select="a:Test[1]"/>
    961                                                     <xsl:with-param name="testDate" select="$testDate"/>
    962                                                 </xsl:call-template>
    963                                             </xsl:otherwise>
    964                                         </xsl:choose>
    965                                     </entry>
    966                                 </xsl:for-each>
    967                             </section>
    968                         </component>
    969                     </xsl:if>
    970777</section>
    971778</component>
Note: See TracChangeset for help on using the changeset viewer.