projects
/
pazpar2-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' into paz-927
[pazpar2-moved-to-github.git]
/
etc
/
cf.xsl
diff --git
a/etc/cf.xsl
b/etc/cf.xsl
index
49c2a1a
..
7796273
100644
(file)
--- a/
etc/cf.xsl
+++ b/
etc/cf.xsl
@@
-26,7
+26,16
@@
<xsl:template match="/record">
<pz:record>
<pz:metadata type="medium">
<xsl:template match="/record">
<pz:record>
<pz:metadata type="medium">
- <xsl:value-of select="$medium" />
+ <xsl:choose>
+ <xsl:when test="string-length($medium)">
+ <xsl:value-of select="$medium" />
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:if test="medium">
+ <xsl:value-of select="medium" />
+ </xsl:if>
+ </xsl:otherwise>
+ </xsl:choose>
</pz:metadata>
<xsl:apply-templates/>
</pz:record>
</pz:metadata>
<xsl:apply-templates/>
</pz:record>
@@
-76,6
+85,9
@@
-->
<xsl:template match="item">
-->
<xsl:template match="item">
+ <pz:metadata type="due" empty="PAZPAR2_NULL_VALUE">
+ <xsl:value-of select="due"/>
+ </pz:metadata>
<pz:metadata type="locallocation" empty="PAZPAR2_NULL_VALUE">
<xsl:value-of select="location"/>
</pz:metadata>
<pz:metadata type="locallocation" empty="PAZPAR2_NULL_VALUE">
<xsl:value-of select="location"/>
</pz:metadata>
@@
-101,6
+113,9
@@
<xsl:value-of select="."/>
</pz:metadata>
</xsl:template>
<xsl:value-of select="."/>
</pz:metadata>
</xsl:template>
+
+ <!-- no-op template to avoid printing medium out -->
+ <xsl:template match="medium" />
<xsl:template match="*" >
<pz:metadata type="{local-name()}">
<xsl:template match="*" >
<pz:metadata type="{local-name()}">