Looks in more places for system-control-nr
authorNiels Erik G. Nielsen <nielserik@indexdata.com>
Wed, 26 May 2010 16:13:56 +0000 (09:13 -0700)
committerNiels Erik G. Nielsen <nielserik@indexdata.com>
Wed, 26 May 2010 16:13:56 +0000 (09:13 -0700)
...if 035$a not found the try 035$b

etc/tmarc.xsl

index 8ecdf18..f561f81 100644 (file)
         </pz:metadata>
       </xsl:for-each>
 
-      <xsl:for-each select="tmarc:d035">
+      <xsl:for-each select="tmarc:d035"> 
         <pz:metadata type="system-control-nr">
-          <xsl:value-of select="tmarc:sa" />
+          <xsl:choose>
+            <xsl:when test="tmarc:sa">
+              <xsl:value-of select="tmarc:sa"/>
+            </xsl:when>
+            <xsl:otherwise>
+              <xsl:value-of select="tmarc:sb"/>
+            </xsl:otherwise>
+          </xsl:choose>
         </pz:metadata>
       </xsl:for-each>