3151. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 6/9/2017 3:49:50 PM Eastern Daylight Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

3151.1 Files compared

# Location File Last Modified
1 Fri Jun 9 19:49:50 2017 UTC
2 eHealth_Exch (eHealth Exchange Enhancements) Build 3 docs & code_May_2017.zip\VAP_CIF_CODE0502.zip\VAP_CIF_CODE0502\VAP_CIF_CODE0502\nvap-client\src\main\resources\gov\va\nvap\document\xsl\adapter detailCommon.xsl Wed Jun 7 05:21:50 2017 UTC

3151.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 0 0
Changed 0 0
Inserted 1 1702
Removed 0 0

3151.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

3151.4 Active regular expressions

No regular expressions were active.

3151.5 Comparison detail

        1   <?xml 
        2     version="1 .0" 
        3     encoding=" utf-8"
        4   ?>
        5  
        6   <xsl:style sheet 
        7     version="1 .0" 
        8     xmlns:n1=" urn:hl7-or g:v3"
        9           
        10     xmlns:xsi= "http://ww w.w3.org/2 001/XMLSch ema-instan ce" 
        11     xmlns:xsl= "http://ww w.w3.org/1 999/XSL/Tr ansform"
        12   >
        13             
        14     <!-- ASHA  AMRITRAJ -  Comment c haining im port, the  stylesheet s cannot i mport 
        15                      itse lf! <xsl:i mport href ="nhinComm on.xsl"/>  -->
        16    
        17             
        18     <xsl:varia ble 
        19      name="snom edCode"
        20     >
        21                       2.16 .840.1.113 883.6.96
        22              
        23     </xsl:vari able>
        24             
        25     <xsl:varia ble 
        26      name="snom edProblemC ode"
        27     >
        28                       5560 7006
        29              
        30     </xsl:vari able>
        31             
        32     <xsl:varia ble 
        33      name="snom edProblemC ode2"
        34     >
        35                       4046 84003
        36              
        37     </xsl:vari able>
        38             
        39     <xsl:varia ble 
        40      name="snom edProblemC ode3"
        41     >
        42                       4187 99008
        43              
        44     </xsl:vari able>
        45             
        46     <xsl:varia ble 
        47      name="snom edAllergyC ode"
        48     >
        49                       4160 98002
        50              
        51     </xsl:vari able>
        52    
        53             
        54     <xsl:varia ble 
        55      name="loin cCode"
        56     >
        57                       2.16 .840.1.113 883.6.1
        58              
        59     </xsl:vari able>
        60             
        61     <xsl:varia ble 
        62      name="loin cProblemCo de"
        63     >
        64                       1145 0-4
        65              
        66     </xsl:vari able>
        67             
        68     <xsl:varia ble 
        69      name="loin cAllergyCo de"
        70     >
        71                       4876 5-2
        72              
        73     </xsl:vari able>
        74             
        75     <xsl:varia ble 
        76      name="loin cMedCode"
        77     >
        78                       1016 0-0
        79              
        80     </xsl:vari able>
        81             
        82     <xsl:varia ble 
        83      name="loin cEncounter Code"
        84     >
        85                       4624 0-8
        86              
        87     </xsl:vari able>
        88             
        89     <xsl:varia ble 
        90      name="loin cResultsCo de"
        91     >
        92                       3095 4-2
        93              
        94     </xsl:vari able>
        95             
        96     <xsl:varia ble 
        97      name="loin cProcedure sCode"
        98     >
        99                       4751 9-4
        100              
        101     </xsl:vari able>
        102             
        103     <xsl:varia ble 
        104      name="loin cImmunizat ionsCode"
        105     >
        106                       1136 9-6
        107              
        108     </xsl:vari able>
        109             
        110     <xsl:varia ble 
        111      name="loin cVitalsCod e"
        112     >
        113                       8716 -3
        114              
        115     </xsl:vari able>
        116    
        117             
        118     <xsl:varia ble 
        119      name="vita lsTemplate Code"
        120     >
        121                       2.16 .840.1.113 883.10.20. 1.32
        122              
        123     </xsl:vari able>
        124             
        125     <xsl:varia ble 
        126      name="labs TemplateCo de"
        127     >
        128                       2.16 .840.1.113 883.10.20. 1.32
        129              
        130     </xsl:vari able>
        131             
        132     <xsl:varia ble 
        133      name="immu nizationsT emplateCod e"
        134     >
        135                       2.16 .840.1.113 883.10.20. 1.32
        136              
        137     </xsl:vari able>
        138             
        139     <xsl:varia ble 
        140      name="alle rgyTemplat eCode"
        141     >
        142                       2.16 .840.1.113 883.10.20. 1.18
        143              
        144     </xsl:vari able>
        145             
        146     <xsl:varia ble 
        147      name="prob lemTemplat eCode"
        148     >
        149                       2.16 .840.1.113 883.10.20. 1.28
        150              
        151     </xsl:vari able>
        152    
        153             
        154     <xsl:varia ble 
        155      name="row"
        156     >
        157                       "Cli nicalDocum ent/"
        158              
        159     </xsl:vari able>
        160    
        161             
        162     <xsl:varia ble 
        163      name="titl e"
        164     >
        165                       
        166      <xsl:choos e>
        167                                 
        168       <xsl:when 
        169        test="stri ng-length( /n1:Clinic alDocument /n1:title) =0"
        170       >
        171                                           
        172        <xsl:text>
        173         Clinical D ocument
        174        </xsl:text >
        175                                  
        176       </xsl:when >
        177                                 
        178       <xsl:when 
        179        test="/n1: ClinicalDo cument/n1: title"
        180       >
        181                                           
        182        <xsl:value -of 
        183         select="/n 1:Clinical Document/n 1:title" 
        184        />
        185                                  
        186       </xsl:when >
        187                        
        188      </xsl:choo se>
        189              
        190     </xsl:vari able>
        191    
        192             
        193     <!-- Forma t Date out puts a dat e in Month  Day, Year  form e.g. , 19991207  ==> 
        194                      Dec  07, 99 -->
        195             
        196     <xsl:templ ate 
        197      name="form atDate"
        198     >
        199                       
        200      <xsl:param  
        201       name="date
        202      />
        203                       
        204      <xsl:if 
        205       test="stri ng-length( $date)>0"
        206      >
        207                                 
        208       <xsl:varia ble 
        209        name="mont h" 
        210        select="su bstring ($ date, 5, 2 )" 
        211       />
        212                                 
        213       <xsl:choos e>
        214                                           
        215        <xsl:when 
        216         test="$mon th='01'"
        217        >
        218                                                    
        219         <xsl:text>
        220          Jan 
        221         </xsl:text >
        222                                            
        223        </xsl:when >
        224                                           
        225        <xsl:when 
        226         test="$mon th='02'"
        227        >
        228                                                    
        229         <xsl:text>
        230          Feb 
        231         </xsl:text >
        232                                            
        233        </xsl:when >
        234                                           
        235        <xsl:when 
        236         test="$mon th='03'"
        237        >
        238                                                    
        239         <xsl:text>
        240          Mar 
        241         </xsl:text >
        242                                            
        243        </xsl:when >
        244                                           
        245        <xsl:when 
        246         test="$mon th='04'"
        247        >
        248                                                    
        249         <xsl:text>
        250          Apr 
        251         </xsl:text >
        252                                            
        253        </xsl:when >
        254                                           
        255        <xsl:when 
        256         test="$mon th='05'"
        257        >
        258                                                    
        259         <xsl:text>
        260          May 
        261         </xsl:text >
        262                                            
        263        </xsl:when >
        264                                           
        265        <xsl:when 
        266         test="$mon th='06'"
        267        >
        268                                                    
        269         <xsl:text>
        270          Jun 
        271         </xsl:text >
        272                                            
        273        </xsl:when >
        274                                           
        275        <xsl:when 
        276         test="$mon th='07'"
        277        >
        278                                                    
        279         <xsl:text>
        280          Jul 
        281         </xsl:text >
        282                                            
        283        </xsl:when >
        284                                           
        285        <xsl:when 
        286         test="$mon th='08'"
        287        >
        288                                                    
        289         <xsl:text>
        290          Aug 
        291         </xsl:text >
        292                                            
        293        </xsl:when >
        294                                           
        295        <xsl:when 
        296         test="$mon th='09'"
        297        >
        298                                                    
        299         <xsl:text>
        300          Sep 
        301         </xsl:text >
        302                                            
        303        </xsl:when >
        304                                           
        305        <xsl:when 
        306         test="$mon th='10'"
        307        >
        308                                                    
        309         <xsl:text>
        310          Oct 
        311         </xsl:text >
        312                                            
        313        </xsl:when >
        314                                           
        315        <xsl:when 
        316         test="$mon th='11'"
        317        >
        318                                                    
        319         <xsl:text>
        320          Nov 
        321         </xsl:text >
        322                                            
        323        </xsl:when >
        324                                           
        325        <xsl:when 
        326         test="$mon th='12'"
        327        >
        328                                                    
        329         <xsl:text>
        330          Dec 
        331         </xsl:text >
        332                                            
        333        </xsl:when >
        334                                  
        335       </xsl:choo se>
        336                                 
        337       <xsl:choos e>
        338                                           
        339        <xsl:when 
        340         test='subs tring ($da te, 7, 1)= "0"'
        341        >
        342                                                    
        343         <xsl:value -of 
        344          select="su bstring ($ date, 8, 1 )" 
        345         />
        346                                                    
        347         <xsl:text>
        348         
        349         </xsl:text >
        350                                            
        351        </xsl:when >
        352                                           
        353        <xsl:other wise>
        354                                                    
        355         <xsl:value -of 
        356          select="su bstring ($ date, 7, 2 )" 
        357         />
        358                                                    
        359         <xsl:text>
        360         
        361         </xsl:text >
        362                                            
        363        </xsl:othe rwise>
        364                                  
        365       </xsl:choo se>
        366                                 
        367       <xsl:value -of 
        368        select="su bstring ($ date, 3, 2 )" 
        369       />
        370                        
        371      </xsl:if>
        372              
        373     </xsl:temp late>
        374    
        375             
        376     <!-- Forma t Date out puts a dat e in Month  Day, Year  form e.g. , 19991207  ==> 
        377                      Dece mber 07, 1 999 -->
        378             
        379     <xsl:templ ate 
        380      name="form atDateFull "
        381     >
        382                       
        383      <xsl:param  
        384       name="date
        385      />
        386                       
        387      <xsl:varia ble 
        388       name="mont h" 
        389       select="su bstring ($ date, 5, 2 )" 
        390      />
        391                       
        392      <xsl:choos e>
        393                                 
        394       <xsl:when 
        395        test="$mon th='01'"
        396       >
        397                                           
        398        <xsl:text>
        399         January 
        400        </xsl:text >
        401                                  
        402       </xsl:when >
        403                                 
        404       <xsl:when 
        405        test="$mon th='02'"
        406       >
        407                                           
        408        <xsl:text>
        409         February 
        410        </xsl:text >
        411                                  
        412       </xsl:when >
        413                                 
        414       <xsl:when 
        415        test="$mon th='03'"
        416       >
        417                                           
        418        <xsl:text>
        419         March 
        420        </xsl:text >
        421                                  
        422       </xsl:when >
        423                                 
        424       <xsl:when 
        425        test="$mon th='04'"
        426       >
        427                                           
        428        <xsl:text>
        429         April 
        430        </xsl:text >
        431                                  
        432       </xsl:when >
        433                                 
        434       <xsl:when 
        435        test="$mon th='05'"
        436       >
        437                                           
        438        <xsl:text>
        439         May 
        440        </xsl:text >
        441                                  
        442       </xsl:when >
        443                                 
        444       <xsl:when 
        445        test="$mon th='06'"
        446       >
        447                                           
        448        <xsl:text>
        449         June 
        450        </xsl:text >
        451                                  
        452       </xsl:when >
        453                                 
        454       <xsl:when 
        455        test="$mon th='07'"
        456       >
        457                                           
        458        <xsl:text>
        459         July 
        460        </xsl:text >
        461                                  
        462       </xsl:when >
        463                                 
        464       <xsl:when 
        465        test="$mon th='08'"
        466       >
        467                                           
        468        <xsl:text>
        469         August 
        470        </xsl:text >
        471                                  
        472       </xsl:when >
        473                                 
        474       <xsl:when 
        475        test="$mon th='09'"
        476       >
        477                                           
        478        <xsl:text>
        479         September 
        480        </xsl:text >
        481                                  
        482       </xsl:when >
        483                                 
        484       <xsl:when 
        485        test="$mon th='10'"
        486       >
        487                                           
        488        <xsl:text>
        489         October 
        490        </xsl:text >
        491                                  
        492       </xsl:when >
        493                                 
        494       <xsl:when 
        495        test="$mon th='11'"
        496       >
        497                                           
        498        <xsl:text>
        499         November 
        500        </xsl:text >
        501                                  
        502       </xsl:when >
        503                                 
        504       <xsl:when 
        505        test="$mon th='12'"
        506       >
        507                                           
        508        <xsl:text>
        509         December 
        510        </xsl:text >
        511                                  
        512       </xsl:when >
        513                        
        514      </xsl:choo se>
        515                       
        516      <xsl:choos e>
        517                                 
        518       <xsl:when 
        519        test='subs tring ($da te, 7, 1)= "0"'
        520       >
        521                                           
        522        <xsl:value -of 
        523         select="su bstring ($ date, 8, 1 )" 
        524        />
        525                                           
        526        <xsl:text>
        527        
        528        </xsl:text >
        529                                  
        530       </xsl:when >
        531                                 
        532       <xsl:other wise>
        533                                           
        534        <xsl:value -of 
        535         select="su bstring ($ date, 7, 2 )" 
        536        />
        537                                           
        538        <xsl:text>
        539        
        540        </xsl:text >
        541                                  
        542       </xsl:othe rwise>
        543                        
        544      </xsl:choo se>
        545                       
        546      <xsl:value -of 
        547       select="su bstring ($ date, 1, 4 )" 
        548      />
        549              
        550     </xsl:temp late>
        551    
        552             
        553     <xsl:templ ate 
        554      name="getM edName"
        555     >
        556                       
        557      <xsl:param  
        558       name="subs tanceAdmin
        559      />
        560                       
        561      <xsl:varia ble 
        562       name="ref1 "
        563                                
        564       select="$s ubstanceAd min/n1:con sumable/n1 :manufactu redProduct /n1:manufa cturedMate rial/n1:co de/n1:orig inalText/n 1:referenc e/@value" 
        565      />
        566                       
        567      <xsl:if 
        568       test="$sub stanceAdmi n"
        569      >
        570                                 
        571       <xsl:choos e>
        572                                           
        573        <xsl:when 
        574         test="../n 1:text/n1: list/n1:it em/n1:cont ent[@ID=$r ef1]"
        575        >
        576                                                    
        577         <xsl:value -of
        578                                                             
        579          select="$r ow/../n1:t ext/n1:lis t/n1:item/ n1:content [@ID=$ref1 ]" 
        580         />
        581                                            
        582        </xsl:when >
        583                                           
        584        <xsl:when 
        585         test="../n 1:text/n1: content[@I D=substrin g-after($r ef1,'#')]"
        586        >
        587                                                    
        588         <xsl:value -of
        589                                                             
        590          select=".. /n1:text/n 1:content[ @ID=substr ing-after( $ref1,'#') ]" 
        591         />
        592                                            
        593        </xsl:when >
        594                                           
        595        <xsl:when
        596                                                   
        597         test="$sub stanceAdmi n/n1:consu mable/n1:m anufacture dProduct/n 1:manufact uredMateri al/n1:code /n1:origin alText"
        598        >
        599                                                    
        600         <xsl:value -of
        601                                                             
        602          select="$s ubstanceAd min/n1:con sumable/n1 :manufactu redProduct /n1:manufa cturedMate rial/n1:co de/n1:orig inalText" 
        603         />
        604                                            
        605        </xsl:when >
        606                                           
        607        <xsl:when
        608                                                   
        609         test="$sub stanceAdmi n/n1:consu mable/n1:m anufacture dProduct/n 1:manufact uredMateri al/n1:code /@displayN ame"
        610        >
        611                                                    
        612         <xsl:value -of
        613                                                             
        614          select="$s ubstanceAd min/n1:con sumable/n1 :manufactu redProduct /n1:manufa cturedMate rial/n1:co de/@displa yName" 
        615         />
        616                                            
        617        </xsl:when >
        618                                           
        619        <xsl:other wise>
        620                                                    
        621         <xsl:value -of
        622                                                             
        623          select="$s ubstanceAd min/n1:con sumable/n1 :manufactu redProduct /n1:manufa cturedMate rial/n1:na me" 
        624         />
        625                                            
        626        </xsl:othe rwise>
        627                                  
        628       </xsl:choo se>
        629                        
        630      </xsl:if>
        631              
        632     </xsl:temp late>
        633    
        634             
        635     <xsl:templ ate 
        636      name="medS tatus"
        637     >
        638                       
        639      <xsl:param  
        640       name="subs tanceAdmin
        641      />
        642                       
        643      <xsl:varia ble 
        644       name="stat us"
        645      >
        646                                 
        647       <xsl:call- template 
        648        name="getM edStatusSt ring"
        649       >
        650                                           
        651        <xsl:with- param 
        652         name="subs tanceAdmin
        653         select="$s ubstanceAd min" 
        654        />
        655                                  
        656       </xsl:call -template>
        657                        
        658      </xsl:vari able>
        659                       
        660      <xsl:choos e>
        661                                 
        662       <xsl:when 
        663        test="stri ng-length( $status)&g t;0"
        664       >
        665                                           
        666        <xsl:value -of 
        667         select="$s tatus" 
        668        />
        669                                  
        670       </xsl:when >
        671                                 
        672       <xsl:other wise>
        673                                           
        674        <xsl:call- template 
        675         name="na" 
        676        />
        677                                  
        678       </xsl:othe rwise>
        679                        
        680      </xsl:choo se>
        681              
        682     </xsl:temp late>
        683    
        684             
        685     <xsl:templ ate 
        686      name="medQ uantity"
        687     >
        688                       
        689      <xsl:param  
        690       name="subs tanceAdmin
        691      />
        692                       
        693      <xsl:varia ble 
        694       name="qtyS tring"
        695      >
        696                                 
        697       <xsl:call- template 
        698        name="getM edQuantity String"
        699       >
        700                                           
        701        <xsl:with- param 
        702         name="subs tanceAdmin
        703         select="$s ubstanceAd min" 
        704        />
        705                                  
        706       </xsl:call -template>
        707                        
        708      </xsl:vari able>
        709                       
        710      <xsl:choos e>
        711                                 
        712       <xsl:when 
        713        test="stri ng-length( $qtyString )>0"
        714       >
        715                                           
        716        <xsl:value -of 
        717         select="$q tyString" 
        718        />
        719                                  
        720       </xsl:when >
        721                                 
        722       <xsl:other wise>
        723                                           
        724        <xsl:call- template 
        725         name="na" 
        726        />
        727                                  
        728       </xsl:othe rwise>
        729                        
        730      </xsl:choo se>
        731              
        732     </xsl:temp late>
        733    
        734             
        735     <xsl:templ ate 
        736      name="medB egintime"
        737     >
        738                       
        739      <xsl:param  
        740       name="row"  
        741      />
        742                       
        743      <xsl:varia ble 
        744       name="medB eginString "
        745      >
        746                                 
        747       <xsl:call- template 
        748        name="medD ateBeginSt ring"
        749       >
        750                                           
        751        <xsl:with- param 
        752         name="subs tanceAdmin "
        753                                                   
        754         select="$r ow/n1:subs tanceAdmin istration"  
        755        />
        756                                  
        757       </xsl:call -template>
        758                        
        759      </xsl:vari able>
        760                       
        761      <xsl:choos e>
        762                                 
        763       <xsl:when 
        764        test="stri ng-length( $medBeginS tring)&gt; 1"
        765       >
        766                                           
        767        <xsl:call- template 
        768         name="form atDate"
        769        >
        770                                                    
        771         <xsl:with- param 
        772          name="date
        773          select="$m edBeginStr ing" 
        774         />
        775                                            
        776        </xsl:call -template>
        777                                  
        778       </xsl:when >
        779                                 
        780       <xsl:other wise>
        781                                           
        782        <xsl:call- template 
        783         name="na" 
        784        />
        785                                  
        786       </xsl:othe rwise>
        787                        
        788      </xsl:choo se>
        789              
        790     </xsl:temp late>
        791    
        792             
        793     <xsl:templ ate 
        794      name="medE xpiretime"
        795     >
        796                       
        797      <xsl:param  
        798       name="subs tanceAdmin
        799      />
        800                       
        801      <xsl:varia ble 
        802       name="medE xpireStrin g"
        803      >
        804                                 
        805       <xsl:call- template 
        806        name="medE xpireDateS tring"
        807       >
        808                                           
        809        <xsl:with- param 
        810         name="subs tanceAdmin
        811         select="$s ubstanceAd min" 
        812        />
        813                                  
        814       </xsl:call -template>
        815                        
        816      </xsl:vari able>
        817                       
        818      <xsl:choos e>
        819                                 
        820       <xsl:when 
        821        test="stri ng-length( $medExpire String)>1"
        822       >
        823                                           
        824        <xsl:call- template 
        825         name="form atDate"
        826        >
        827                                                    
        828         <xsl:with- param 
        829          name="date
        830          select="$m edExpireSt ring" 
        831         />
        832                                            
        833        </xsl:call -template>
        834                                  
        835       </xsl:when >
        836                                 
        837       <xsl:other wise>
        838                                           
        839        <xsl:call- template 
        840         name="na" 
        841        />
        842                                  
        843       </xsl:othe rwise>
        844                        
        845      </xsl:choo se>
        846              
        847     </xsl:temp late>
        848    
        849             
        850     <xsl:templ ate 
        851      name="prob Name"
        852     >
        853                       
        854      <xsl:param  
        855       name="ref"  
        856      />
        857                       
        858      <xsl:param  
        859       name="rowD ata" 
        860      />
        861                       
        862      <xsl:varia ble 
        863       name="prob Reference1
        864       select="$r ef/@value"  
        865      />
        866                       
        867      <!--<xsl:v ariable na me="probRe ference2"  select="$r ef/@value" /> -->
        868                       
        869      <xsl:choos e>
        870                                 
        871       <xsl:when 
        872        test="../n 1:text/n1: paragraph[ @ID=$probR eference1] "
        873       >
        874                                           
        875        <xsl:value -of 
        876         select=".. /n1:text/n 1:paragrap h[@ID=$pro bReference 1]" 
        877        />
        878                                  
        879       </xsl:when >
        880      
        881                                 
        882       <xsl:when
        883                                          
        884        test="../n 1:text/n1: paragraph[ @ID=substr ing-after( $probRefer ence1,'#') ]"
        885       >
        886                                           
        887        <xsl:value -of
        888                                                   
        889         select=".. /n1:text/n 1:paragrap h[@ID=subs tring-afte r($probRef erence1,'# ')]" 
        890        />
        891                                  
        892       </xsl:when >
        893      
        894                                 
        895       <!--DoD -- >
        896                                 
        897       <xsl:when
        898                                          
        899        test="../n 1:text/n1: table/n1:t body/n1:tr /n1:td/n1: content[@I D=substrin g-after($p robReferen ce1,'#')]"
        900       >
        901                                           
        902        <xsl:value -of
        903                                                   
        904         select=".. /n1:text/n 1:table/n1 :tbody/n1: tr/n1:td/n 1:content[ @ID=substr ing-after( $probRefer ence1,'#') ]" 
        905        />
        906                                  
        907       </xsl:when >
        908      
        909                                 
        910       <xsl:when
        911                                          
        912        test="../n 1:text/n1: table/n1:t body/n1:tr /n1:td[@ID =substring -after($pr obReferenc e1,'#')]"
        913       >
        914                                           
        915        <xsl:value -of
        916                                                   
        917         select=".. /n1:text/n 1:table/n1 :tbody/n1: tr/n1:td[@ ID=substri ng-after($ probRefere nce1,'#')]
        918        />
        919                                  
        920       </xsl:when >
        921      
        922                                 
        923       <xsl:when 
        924        test="../n 1:text/n1: content[@I D=$probRef erence1]"
        925       >
        926                                           
        927        <xsl:value -of 
        928         select=".. /n1:text/n 1:content[ @ID=$probR eference1]
        929        />
        930                                  
        931       </xsl:when >
        932                                 
        933       <xsl:when
        934                                          
        935        test="../n 1:text/n1: content[@I D=substrin g-after($p robReferen ce1,'#')]"
        936       >
        937                                           
        938        <xsl:value -of
        939                                                   
        940         select=".. /n1:text/n 1:content[ @ID=substr ing-after( $probRefer ence1,'#') ]" 
        941        />
        942                                  
        943       </xsl:when >
        944                                 
        945       <xsl:other wise>
        946                                           
        947        <xsl:call- template 
        948         name="na" 
        949        />
        950                                  
        951       </xsl:othe rwise>
        952                        
        953      </xsl:choo se>
        954              
        955     </xsl:temp late>
        956    
        957             
        958     <xsl:templ ate 
        959      name="prob Status"
        960     >
        961                       
        962      <xsl:param  
        963       name="row"  
        964      />
        965                       
        966      <xsl:choos e>
        967                                 
        968       <xsl:when
        969                                          
        970        test="$row /n1:act/n1 :entryRela tionship[@ typeCode=' SUBJ']/n1: observatio n/n1:entry Relationsh ip[@typeCo de='REFR'] /n1:observ ation/n1:v alue/@disp layName"
        971       >
        972                                           
        973        <xsl:value -of
        974                                                   
        975         select="$r ow/n1:act/ n1:entryRe lationship [@typeCode ='SUBJ']/n 1:observat ion/n1:ent ryRelation ship[@type Code='REFR ']/n1:obse rvation/n1 :value/@di splayName"  
        976        />
        977                                  
        978       </xsl:when >
        979                                 
        980       <xsl:when
        981                                          
        982        test="$row /n1:act/n1 :entryRela tionship[@ typeCode=' REFR']/n1: observatio n/n1:value /@displayN ame"
        983       >
        984                                           
        985        <xsl:value -of
        986                                                   
        987         select="$r ow/n1:act/ n1:entryRe lationship [@typeCode ='REFR']/n 1:observat ion/n1:val ue/@displa yName" 
        988        />
        989                                  
        990       </xsl:when >
        991                                 
        992       <xsl:other wise>
        993                                           
        994        <xsl:call- template 
        995         name="na" 
        996        />
        997                                  
        998       </xsl:othe rwise>
        999                        
        1000      </xsl:choo se>
        1001              
        1002     </xsl:temp late>
        1003    
        1004             
        1005     <xsl:templ ate 
        1006      name="prob Date"
        1007     >
        1008                       
        1009      <xsl:param  
        1010       name="row"  
        1011      />
        1012                       
        1013      <xsl:varia ble 
        1014       name="rawD ate"
        1015      >
        1016                                 
        1017       <xsl:call- template 
        1018        name="getP roblemOnse tDateStrin g"
        1019       >
        1020                                           
        1021        <xsl:with- param 
        1022         name="act"  
        1023         select="$r ow/n1:act"  
        1024        />
        1025                                  
        1026       </xsl:call -template>
        1027                        
        1028      </xsl:vari able>
        1029                       
        1030      <xsl:choos e>
        1031                                 
        1032       <xsl:when 
        1033        test="stri ng-length( $rawDate)> 1"
        1034       >
        1035                                           
        1036        <xsl:call- template 
        1037         name="form atDate"
        1038        >
        1039                                                    
        1040         <xsl:with- param 
        1041          name="date
        1042          select="$r awDate" 
        1043         />
        1044                                            
        1045        </xsl:call -template>
        1046                                  
        1047       </xsl:when >
        1048                                 
        1049       <xsl:other wise>
        1050                                           
        1051        <xsl:call- template 
        1052         name="na" 
        1053        />
        1054                                  
        1055       </xsl:othe rwise>
        1056                        
        1057      </xsl:choo se>
        1058              
        1059     </xsl:temp late>
        1060    
        1061             
        1062     <xsl:templ ate 
        1063      name="alle rgyType"
        1064     >
        1065                       
        1066      <xsl:param  
        1067       name="row"  
        1068      />
        1069                       
        1070      <xsl:choos e>
        1071                                 
        1072       <xsl:when 
        1073        test="$row /n1:code"
        1074       >
        1075                                           
        1076        <xsl:choos e>
        1077                                                    
        1078         <xsl:when 
        1079          test="$row /n1:code/n 1:original Text"
        1080         >
        1081                                                              
        1082          <xsl:value -of 
        1083           select="$r ow/n1:code /n1:origin alText" 
        1084          />
        1085                                                     
        1086         </xsl:when >
        1087                                                    
        1088         <xsl:when 
        1089          test="$row /n1:code/@ displayNam e"
        1090         >
        1091                                                              
        1092          <xsl:value -of 
        1093           select="$r ow/n1:code /@displayN ame" 
        1094          />
        1095                                                     
        1096         </xsl:when >
        1097                                                    
        1098         <xsl:other wise>
        1099                                                              
        1100          <xsl:call- template 
        1101           name="na" 
        1102          />
        1103                                                     
        1104         </xsl:othe rwise>
        1105                                            
        1106        </xsl:choo se>
        1107                                  
        1108       </xsl:when >
        1109                                 
        1110       <xsl:other wise>
        1111                                           
        1112        <xsl:call- template 
        1113         name="na" 
        1114        />
        1115                                  
        1116       </xsl:othe rwise>
        1117                        
        1118      </xsl:choo se>
        1119              
        1120     </xsl:temp late>
        1121    
        1122             
        1123     <xsl:templ ate 
        1124      name="alle rgySource"
        1125     >
        1126                       
        1127      <xsl:param  
        1128       name="row"  
        1129      />
        1130                       
        1131      <xsl:param  
        1132       name="isPl aintext" 
        1133       select="bo olean(true )" 
        1134      />
        1135                       
        1136      <xsl:choos e>
        1137                                 
        1138       <xsl:when
        1139                                          
        1140        test="$row /n1:act/n1 :author/n1 :assignedA uthor/n1:r epresented Organizati on/n1:name "
        1141       >
        1142                                           
        1143        <xsl:value -of
        1144                                                   
        1145         select="$r ow/n1:act/ n1:author/ n1:assigne dAuthor/n1 :represent edOrganiza tion/n1:na me" 
        1146        />
        1147                                  
        1148       </xsl:when >
        1149                                 
        1150       <xsl:other wise>
        1151                                           
        1152        <xsl:call- template 
        1153         name="na" 
        1154        />
        1155                                  
        1156       </xsl:othe rwise>
        1157                        
        1158      </xsl:choo se>
        1159              
        1160     </xsl:temp late>
        1161    
        1162             
        1163     <xsl:templ ate 
        1164      name="na"
        1165     >
        1166                       
        1167      <xsl:text>
        1168       - Not Avai lable -
        1169      </xsl:text >
        1170              
        1171     </xsl:temp late>
        1172    
        1173             
        1174     <xsl:templ ate 
        1175      name="getC reatedOnDa te"
        1176     >
        1177                       
        1178      <xsl:choos e>
        1179                                 
        1180       <xsl:when
        1181                                          
        1182        test="stri ng-length( /n1:Clinic alDocument /n1:effect iveTime/@v alue)=0"
        1183       >
        1184                                           
        1185        <xsl:call- template 
        1186         name="na" 
        1187        />
        1188                                  
        1189       </xsl:when >
        1190                                 
        1191       <xsl:when
        1192                                          
        1193        test="star ts-with(/n 1:Clinical Document/n 1:effectiv eTime/@val ue,' ')"
        1194       >
        1195                                           
        1196        <xsl:call- template 
        1197         name="na" 
        1198        />
        1199                                  
        1200       </xsl:when >
        1201                                 
        1202       <xsl:other wise>
        1203                                           
        1204        <xsl:call- template 
        1205         name="form atDateFull "
        1206        >
        1207                                                    
        1208         <xsl:with- param 
        1209          name="date "
        1210                                                             
        1211          select="/n 1:Clinical Document/n 1:effectiv eTime/@val ue" 
        1212         />
        1213                                            
        1214        </xsl:call -template>
        1215                                  
        1216       </xsl:othe rwise>
        1217                        
        1218      </xsl:choo se>
        1219              
        1220     </xsl:temp late>
        1221    
        1222             
        1223     <xsl:templ ate 
        1224      name="getG enderStrin g"
        1225     >
        1226                       
        1227      <xsl:choos e>
        1228                                 
        1229       <xsl:when
        1230                                          
        1231        test="/n1: ClinicalDo cument/n1: recordTarg et/n1:pati entRole/n1 :patient/n 1:administ rativeGend erCode/@co de"
        1232       >
        1233                                           
        1234        <xsl:value -of
        1235                                                   
        1236         select="/n 1:Clinical Document/n 1:recordTa rget/n1:pa tientRole/ n1:patient /n1:admini strativeGe nderCode/@ code" 
        1237        />
        1238                                  
        1239       </xsl:when >
        1240                                 
        1241       <xsl:other wise>
        1242                                           
        1243        <xsl:call- template 
        1244         name="gend erString"
        1245        >
        1246                                                    
        1247         <xsl:with- param 
        1248          name="sex"
        1249                                                             
        1250          select="/n 1:Clinical Document/n 1:recordTa rget/n1:pa tientRole/ n1:patient /n1:admini strativeGe nderCode/n 1:original Text" 
        1251         />
        1252                                            
        1253        </xsl:call -template>
        1254                                  
        1255       </xsl:othe rwise>
        1256                        
        1257      </xsl:choo se>
        1258              
        1259     </xsl:temp late>
        1260    
        1261             
        1262     <xsl:templ ate 
        1263      name="getR eactionStr ing"
        1264     >
        1265                       
        1266      <xsl:param  
        1267       name="obse rvation" 
        1268      />
        1269                       
        1270      <!--<xsl:f or-each se lect="$obs ervation/n 1:entryRel ationship[ @inversion Ind='true'  
        1271                                and @t ypeCode='M FST']"> -- >
        1272                       
        1273      <xsl:for-e ach 
        1274       select="$o bservation /n1:entryR elationshi p[@typeCod e='MFST']"
        1275      >
        1276                                 
        1277       <!--<xsl:v ariable na me="reacti onReferenc e" select= "substring -after(n1: observatio n/n1:text/ n1:referen ce/@value, '#')"/> -- >
        1278                                 
        1279       <xsl:varia ble 
        1280        name="reac tionRefere nce"
        1281                                          
        1282        select="n1 :observati on/n1:text /n1:refere nce/@value
        1283       />
        1284                                 
        1285       <xsl:varia ble 
        1286        name="reac tionValue"
        1287                                          
        1288        select="/n 1:Clinical Document/n 1:componen t/n1:struc turedBody/ n1:compone nt/n1:sect ion/n1:tex t/n1:conte nt[@ID=$re actionRefe rence]" 
        1289       />
        1290                                 
        1291       <xsl:varia ble 
        1292        name="reac tionValue2 "
        1293                                          
        1294        select="/n 1:Clinical Document/n 1:componen t/n1:struc turedBody/ n1:compone nt/n1:sect ion/n1:tex t/n1:conte nt[@ID=sub string-aft er($reacti onReferenc e,'#')]" 
        1295       />
        1296                                 
        1297       <xsl:varia ble 
        1298        name="reac tion"
        1299                                          
        1300        select=".. /../../../ ../n1:text /n1:conten t[@ID=$rea ctionRefer ence]" 
        1301       />
        1302                                 
        1303       <xsl:if 
        1304        test="stri ng-length( $reactionV alue)>1"
        1305       >
        1306                                           
        1307        <xsl:if 
        1308         test="posi tion()>1"
        1309        >
        1310                                                    
        1311         <xsl:text>
        1312         
        1313         </xsl:text >
        1314                                            
        1315        </xsl:if>
        1316                                           
        1317        <xsl:value -of 
        1318         select="$r eactionVal ue" 
        1319        />
        1320                                  
        1321       </xsl:if>
        1322                                 
        1323       <xsl:if 
        1324        test="stri ng-length( $reactionV alue2)>1"
        1325       >
        1326                                           
        1327        <xsl:if 
        1328         test="posi tion()>1"
        1329        >
        1330                                                    
        1331         <xsl:text>
        1332         
        1333         </xsl:text >
        1334                                            
        1335        </xsl:if>
        1336                                           
        1337        <xsl:value -of 
        1338         select="$r eactionVal ue2" 
        1339        />
        1340                                  
        1341       </xsl:if>
        1342                        
        1343      </xsl:for- each>
        1344              
        1345     </xsl:temp late>
        1346    
        1347             
        1348     <xsl:templ ate 
        1349      name="getS everityStr ing"
        1350     >
        1351                       
        1352      <xsl:param  
        1353       name="obse rvation" 
        1354      />
        1355                       
        1356      <xsl:if 
        1357       test="$obs ervation"
        1358      >
        1359                                 
        1360       <xsl:varia ble 
        1361        name="sevr Reference"
        1362                                          
        1363        select="su bstring-af ter($obser vation/n1: entryRelat ionship/n1 :observati on/n1:entr yRelations hip/n1:obs ervation/n 1:text/n1: reference/ @value,'#' )" 
        1364       />
        1365                                 
        1366       <xsl:varia ble 
        1367        name="seve rity"
        1368                                          
        1369        select="$o bservation /../../../ ../n1:text /n1:conten t[@ID=$sev rReference ]" 
        1370       />
        1371                                 
        1372       <xsl:if 
        1373        test="stri ng-length( $severity) >1"
        1374       >
        1375                                           
        1376        <xsl:value -of 
        1377         select="$s everity" 
        1378        />
        1379                                  
        1380       </xsl:if>
        1381                        
        1382      </xsl:if>
        1383              
        1384     </xsl:temp late>
        1385    
        1386             
        1387     <xsl:templ ate 
        1388      name="getA llergyType "
        1389     >
        1390                       
        1391      <xsl:param  
        1392       name="obse rvation" 
        1393      />
        1394                       
        1395      <xsl:choos e>
        1396                                 
        1397       <xsl:when 
        1398        test="$obs ervation/n 1:code/@di splayName"
        1399       >
        1400                                           
        1401        <xsl:value -of 
        1402         select="ob servation/ n1:code/@d isplayName
        1403        />
        1404                                  
        1405       </xsl:when >
        1406                                 
        1407       <xsl:other wise>
        1408                                           
        1409        <xsl:call- template 
        1410         name="na" 
        1411        />
        1412                                  
        1413       </xsl:othe rwise>
        1414                        
        1415      </xsl:choo se>
        1416              
        1417     </xsl:temp late>
        1418    
        1419             
        1420     <xsl:templ ate 
        1421      name="getS everityTex t"
        1422     >
        1423                       
        1424      <xsl:param  
        1425       name="obse rvation" 
        1426      />
        1427                       
        1428      <xsl:if 
        1429       test="$obs ervation"
        1430      >
        1431                                 
        1432       <xsl:varia ble 
        1433        name="sevr Reference"
        1434                                          
        1435        select="su bstring-af ter($obser vation/n1: entryRelat ionship/n1 :observati on/n1:entr yRelations hip/n1:obs ervation/n 1:text/n1: reference/ @value,'#' )" 
        1436       />
        1437                                 
        1438       <xsl:varia ble 
        1439        name="seve rity"
        1440                                          
        1441        select="$o bservation /../../../ ../n1:text /n1:conten t[@ID=$sev rReference ]" 
        1442       />
        1443                                 
        1444       <xsl:if 
        1445        test="stri ng-length( $severity) >1"
        1446       >
        1447                                           
        1448        <xsl:value -of 
        1449         select="$s everity" 
        1450        />
        1451                                  
        1452       </xsl:if>
        1453                        
        1454      </xsl:if>
        1455              
        1456     </xsl:temp late>
        1457    
        1458             
        1459     <xsl:templ ate 
        1460      name="getP roblemProv iderName"
        1461     >
        1462                       
        1463      <xsl:param  
        1464       name="act"  
        1465      />
        1466                       
        1467      <xsl:if 
        1468       test="$act "
        1469      >
        1470                                 
        1471       <xsl:choos e>
        1472                                           
        1473        <xsl:when
        1474                                                   
        1475         test="$act /n1:entryR elationshi p/n1:obser vation/n1: entryRelat ionship/n1 :observati on[@classC ode='OBS'  and @moodC ode='EVN'] /n1:perfor mer/n1:ass ignedEntit y/n1:assig nedPerson/ n1:name"
        1476        >
        1477                                                    
        1478         <xsl:value -of
        1479                                                             
        1480          select="$a ct/n1:entr yRelations hip/n1:obs ervation/n 1:entryRel ationship/ n1:observa tion[@clas sCode='OBS ' and @moo dCode='EVN ']/n1:perf ormer/n1:a ssignedEnt ity/n1:ass ignedPerso n/n1:name"  
        1481         />
        1482                                            
        1483        </xsl:when >
        1484                                           
        1485        <xsl:when
        1486                                                   
        1487         test="$act /n1:perfor mer/n1:ass ignedEntit y/n1:assig nedPerson/ n1:name"
        1488        >
        1489                                                    
        1490         <xsl:value -of
        1491                                                             
        1492          select="$a ct/n1:perf ormer/n1:a ssignedEnt ity/n1:ass ignedPerso n/n1:name"  
        1493         />
        1494                                            
        1495        </xsl:when >
        1496                                           
        1497        <xsl:when 
        1498         test="$act /n1:perfor mer/n1:ass ignedEntit y/n1:id/@e xtension"
        1499        >
        1500                                                    
        1501         <xsl:varia ble 
        1502          name="prov iderId"
        1503                                                             
        1504          select="$a ct/n1:perf ormer/n1:a ssignedEnt ity/n1:id/ @extension
        1505         />
        1506                                                    
        1507         <xsl:value -of
        1508                                                             
        1509          select="/n 1:Clinical Document/n 1:document ationOf/n1 :serviceEv ent/n1:per former/n1: assignedEn tity/n1:id [@extensio n=$provide rId]/@assi gningAutho rityName" 
        1510         />
        1511                                            
        1512        </xsl:when >
        1513                                           
        1514        <xsl:other wise>
        1515                                                    
        1516         <xsl:value -of
        1517                                                             
        1518          select="$a ct/n1:auth or/n1:assi gnedAuthor /n1:repres entedOrgan ization/n1 :name" 
        1519         />
        1520                                            
        1521        </xsl:othe rwise>
        1522                                  
        1523       </xsl:choo se>
        1524                        
        1525      </xsl:if>
        1526              
        1527     </xsl:temp late>
        1528    
        1529             
        1530     <xsl:templ ate 
        1531      name="getR esultValue "
        1532     >
        1533                       
        1534      <xsl:param  
        1535       name="obse rvation" 
        1536      />
        1537                       
        1538      <xsl:if 
        1539       test="$obs ervation"
        1540      >
        1541                                 
        1542       <xsl:choos e>
        1543                                           
        1544        <xsl:when 
        1545         test="$obs ervation/n 1:value/@v alue"
        1546        >
        1547                                                    
        1548         <xsl:value -of 
        1549          select="$o bservation /n1:value/ @value" 
        1550         />
        1551                                            
        1552        </xsl:when >
        1553                                           
        1554        <xsl:other wise>
        1555                                                    
        1556         <xsl:call- template 
        1557          name="na" 
        1558         />
        1559                                            
        1560        </xsl:othe rwise>
        1561                                  
        1562       </xsl:choo se>
        1563                        
        1564      </xsl:if>
        1565              
        1566     </xsl:temp late>
        1567    
        1568             
        1569     <xsl:templ ate 
        1570      name="getR esultValue Detail"
        1571     >
        1572                       
        1573      <xsl:param  
        1574       name="obse rvation" 
        1575      />
        1576                       
        1577      <xsl:if 
        1578       test="$obs ervation"
        1579      >
        1580                                 
        1581       <xsl:choos e>
        1582                                           
        1583        <xsl:when 
        1584         test="$obs ervation/n 1:value/@v alue"
        1585        >
        1586                                                    
        1587         <xsl:value -of 
        1588          select="$o bservation /n1:value/ @value" 
        1589         />
        1590                                                    
        1591         <xsl:if 
        1592          test="$obs ervation/n 1:value/@u nit"
        1593         >
        1594                                                              
        1595          <xsl:text>
        1596            
        1597          </xsl:text >
        1598                                                              
        1599          <xsl:value -of 
        1600           select="$o bservation /n1:value/ @unit" 
        1601          />
        1602                                                     
        1603         </xsl:if>
        1604                                            
        1605        </xsl:when >
        1606                                           
        1607        <xsl:other wise>
        1608                                                    
        1609         <xsl:call- template 
        1610          name="na" 
        1611         />
        1612                                            
        1613        </xsl:othe rwise>
        1614                                  
        1615       </xsl:choo se>
        1616                        
        1617      </xsl:if>
        1618              
        1619     </xsl:temp late>
        1620    
        1621             
        1622     <xsl:templ ate 
        1623      name="getF lag"
        1624     >
        1625                       
        1626      <xsl:param  
        1627       name="inte rpretation
        1628      />
        1629                       
        1630      <xsl:choos e>
        1631                                 
        1632       <xsl:when 
        1633        test="$int erpretatio n/@display Name"
        1634       >
        1635                                           
        1636        <xsl:value -of 
        1637         select="$i nterpretat ion/@displ ayName" 
        1638        />
        1639                                  
        1640       </xsl:when >
        1641                                 
        1642       <xsl:when 
        1643        test="$int erpretatio n/n1:origi nalText"
        1644       >
        1645                                           
        1646        <xsl:value -of 
        1647         select="$i nterpretat ion/n1:ori ginalText"  
        1648        />
        1649                                  
        1650       </xsl:when >
        1651                                 
        1652       <xsl:other wise>
        1653                                           
        1654        <xsl:call- template 
        1655         name="na" 
        1656        />
        1657                                  
        1658       </xsl:othe rwise>
        1659                        
        1660      </xsl:choo se>
        1661              
        1662     </xsl:temp late>
        1663    
        1664             
        1665     <xsl:templ ate 
        1666      name="getR esultUnit"
        1667     >
        1668                       
        1669      <xsl:param  
        1670       name="obse rvation" 
        1671      />
        1672                       
        1673      <xsl:if 
        1674       test="$obs ervation"
        1675      >
        1676                                 
        1677       <xsl:choos e>
        1678                                           
        1679        <xsl:when 
        1680         test="$obs ervation/n 1:value/@u nit"
        1681        >
        1682                                                    
        1683         <xsl:value -of 
        1684          select="$o bservation /n1:value/ @unit" 
        1685         />
        1686                                            
        1687        </xsl:when >
        1688                                           
        1689        <xsl:other wise>
        1690                                                    
        1691         <xsl:call- template 
        1692          name="na" 
        1693         />
        1694                                            
        1695        </xsl:othe rwise>
        1696                                  
        1697       </xsl:choo se>
        1698                        
        1699      </xsl:if>
        1700              
        1701     </xsl:temp late>
        1702   </xsl:styl esheet>