Lines 12-17
Link Here
|
12 |
<xsl:key name="item-by-status" match="items:item" use="items:status"/> |
12 |
<xsl:key name="item-by-status" match="items:item" use="items:status"/> |
13 |
<xsl:key name="item-by-status-and-branch-home" match="items:item" use="concat(items:status, ' ', items:homebranch)"/> |
13 |
<xsl:key name="item-by-status-and-branch-home" match="items:item" use="concat(items:status, ' ', items:homebranch)"/> |
14 |
<xsl:key name="item-by-status-and-branch-holding" match="items:item" use="concat(items:status, ' ', items:holdingbranch)"/> |
14 |
<xsl:key name="item-by-status-and-branch-holding" match="items:item" use="concat(items:status, ' ', items:holdingbranch)"/> |
|
|
15 |
<xsl:key name="item-by-substatus-and-branch" match="items:item" use="concat(items:substatus, ' ', items:homebranch)"/> |
15 |
|
16 |
|
16 |
<xsl:template match="/"> |
17 |
<xsl:template match="/"> |
17 |
<xsl:apply-templates/> |
18 |
<xsl:apply-templates/> |
Lines 1332-1337
Link Here
|
1332 |
</xsl:when></xsl:choose> |
1333 |
</xsl:when></xsl:choose> |
1333 |
</xsl:when> </xsl:choose> |
1334 |
</xsl:when> </xsl:choose> |
1334 |
|
1335 |
|
|
|
1336 |
<xsl:if test="count(key('item-by-status', 'available'))=0"> |
1337 |
<span class="available"><xsl:value-of select="items:homebranch"/><xsl:text>: </xsl:text></span> |
1338 |
</xsl:if> |
1339 |
|
1340 |
<xsl:choose> |
1341 |
<xsl:when test="count(key('item-by-status', 'reallynotforloan'))>0"> |
1342 |
<span class="unavailable"> |
1343 |
<br /> |
1344 |
<xsl:variable name="reference_items" select="key('item-by-status', 'reallynotforloan')"/> |
1345 |
<xsl:for-each select="$reference_items[generate-id() = generate-id(key('item-by-substatus-and-branch', concat(items:substatus, ' ', items:homebranch))[1])]"> |
1346 |
<xsl:value-of select="items:substatus"/> |
1347 |
<xsl:if test="items:itemcallnumber != '' and items:itemcallnumber"> [<span class="LabelCallNumber">Call number: </span><xsl:value-of select="items:itemcallnumber"/>]</xsl:if> |
1348 |
<xsl:text> (</xsl:text> |
1349 |
<xsl:value-of select="count(key('item-by-substatus-and-branch', concat(items:substatus, ' ', items:homebranch)))"/> |
1350 |
<xsl:text>)</xsl:text> |
1351 |
<xsl:choose><xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when><xsl:otherwise><xsl:text>, </xsl:text></xsl:otherwise></xsl:choose> |
1352 |
</xsl:for-each> |
1353 |
</span> |
1354 |
</xsl:when> |
1355 |
</xsl:choose> |
1356 |
|
1335 |
<xsl:if test="count(key('item-by-status', 'Checked out'))>0"> |
1357 |
<xsl:if test="count(key('item-by-status', 'Checked out'))>0"> |
1336 |
<span class="unavailable"> |
1358 |
<span class="unavailable"> |
1337 |
<xsl:text>Checked out (</xsl:text> |
1359 |
<xsl:text>Checked out (</xsl:text> |
1338 |
- |
|
|