View | Details | Raw Unified | Return to bug 26302
Collapse All | Expand All

(-)a/C4/XSLT.pm (+2 lines)
Lines 173-181 sub get_xslt_sysprefs { Link Here
173
                              TrackClicks opacthemes IdRef OpacSuppression
173
                              TrackClicks opacthemes IdRef OpacSuppression
174
                              OPACResultsLibrary OPACShowOpenURL
174
                              OPACResultsLibrary OPACShowOpenURL
175
                              OpenURLResolverURL OpenURLImageLocation
175
                              OpenURLResolverURL OpenURLImageLocation
176
                              resultsMaxItems
176
                              OpenURLText OPACShowMusicalInscripts OPACPlayMusicalInscripts / )
177
                              OpenURLText OPACShowMusicalInscripts OPACPlayMusicalInscripts / )
177
    {
178
    {
178
        my $sp = C4::Context->preference( $syspref );
179
        my $sp = C4::Context->preference( $syspref );
180
        $sp ||= 1 if $syspref eq 'resultsMaxItems'; # needs default
179
        next unless defined($sp);
181
        next unless defined($sp);
180
        $sysxml .= "<syspref name=\"$syspref\">$sp</syspref>\n";
182
        $sysxml .= "<syspref name=\"$syspref\">$sp</syspref>\n";
181
    }
183
    }
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl (-9 / +33 lines)
Lines 37-42 Link Here
37
    <xsl:variable name="singleBranchMode" select="1"/>
37
    <xsl:variable name="singleBranchMode" select="1"/>
38
    <xsl:variable name="OPACTrackClicks" select="marc:sysprefs/marc:syspref[@name='TrackClicks']"/>
38
    <xsl:variable name="OPACTrackClicks" select="marc:sysprefs/marc:syspref[@name='TrackClicks']"/>
39
    <xsl:variable name="BiblioDefaultView" select="marc:sysprefs/marc:syspref[@name='BiblioDefaultView']"/>
39
    <xsl:variable name="BiblioDefaultView" select="marc:sysprefs/marc:syspref[@name='BiblioDefaultView']"/>
40
    <xsl:variable name="resultsMaxItems" select="marc:sysprefs/marc:syspref[@name='resultsMaxItems']"/>
40
        <xsl:variable name="leader" select="marc:leader"/>
41
        <xsl:variable name="leader" select="marc:leader"/>
41
        <xsl:variable name="leader6" select="substring($leader,7,1)"/>
42
        <xsl:variable name="leader6" select="substring($leader,7,1)"/>
42
        <xsl:variable name="leader7" select="substring($leader,8,1)"/>
43
        <xsl:variable name="leader7" select="substring($leader,8,1)"/>
Lines 1255-1261 Link Here
1255
                               <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1256
                               <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1256
                                   <span class="CallNumberAndLabel">
1257
                                   <span class="CallNumberAndLabel">
1257
                                        <span class="LabelCallNumber">Call number: </span>
1258
                                        <span class="LabelCallNumber">Call number: </span>
1258
                                        <span class="CallNumber"><xsl:value-of select="items:itemcallnumber"/><xsl:if test="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))>1"><xsl:text>, ..</xsl:text></xsl:if></span>
1259
                                        <span class="CallNumber">
1260
                                            <xsl:for-each select="$available_items[position() &lt;= $resultsMaxItems]">
1261
                                                <xsl:value-of select="items:itemcallnumber"/>
1262
                                                <xsl:if test="position()!=last()"><xsl:text>, </xsl:text></xsl:if>
1263
                                            </xsl:for-each>
1264
                                            <xsl:if test="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))>$resultsMaxItems"><xsl:text>, ..</xsl:text></xsl:if>
1265
                                        </span>
1259
                                   </span>
1266
                                   </span>
1260
                               </xsl:if>
1267
                               </xsl:if>
1261
                               <xsl:choose>
1268
                               <xsl:choose>
Lines 1275-1284 Link Here
1275
                                           <xsl:value-of select="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))"/>
1282
                                           <xsl:value-of select="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))"/>
1276
                                       <xsl:text>) </xsl:text>
1283
                                       <xsl:text>) </xsl:text>
1277
                                       <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1284
                                       <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1278
                                           <span class="CallNumberAndLabel">
1285
                                            <span class="CallNumberAndLabel">
1279
                                                <span class="LabelCallNumber">Call number: </span>
1286
                                                <span class="LabelCallNumber">Call number: </span>
1280
                                                <span class="CallNumber"><xsl:value-of select="items:itemcallnumber"/><xsl:if test="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))>1"><xsl:text>, ..</xsl:text></xsl:if></span>
1287
                                                <span class="CallNumber">
1281
                                           </span>
1288
                                                    <xsl:for-each select="$available_items[position() &lt;= $resultsMaxItems]">
1289
                                                        <xsl:value-of select="items:itemcallnumber"/>
1290
                                                        <xsl:if test="position()!=last()"><xsl:text>, </xsl:text></xsl:if>
1291
                                                    </xsl:for-each>
1292
                                                    <xsl:if test="count(key('item-by-status-and-branch-home', concat(items:status, ' ', items:homebranch)))>$resultsMaxItems"><xsl:text>, ..</xsl:text></xsl:if>
1293
                                                </span>
1294
                                            </span>
1282
                                       </xsl:if>
1295
                                       </xsl:if>
1283
                                       <xsl:choose>
1296
                                       <xsl:choose>
1284
                                           <xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when>
1297
                                           <xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when>
Lines 1295-1304 Link Here
1295
                                           <xsl:value-of select="count(key('item-by-status-and-branch-holding', concat(items:status, ' ', items:holdingbranch)))"/>
1308
                                           <xsl:value-of select="count(key('item-by-status-and-branch-holding', concat(items:status, ' ', items:holdingbranch)))"/>
1296
                                       <xsl:text>) </xsl:text>
1309
                                       <xsl:text>) </xsl:text>
1297
                                       <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1310
                                       <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1298
                                           <span class="CallNumberAndLabel">
1311
                                            <span class="CallNumberAndLabel">
1299
                                                <span class="LabelCallNumber">Call number: </span>
1312
                                                <span class="LabelCallNumber">Call number: </span>
1300
                                                <span class="CallNumber"><xsl:value-of select="items:itemcallnumber"/><xsl:if test="count(key('item-by-status-and-branch-holding', concat(items:status, ' ', items:holdingbranch)))>1"><xsl:text>, ..</xsl:text></xsl:if></span>
1313
                                                <span class="CallNumber">
1301
                                           </span>
1314
                                                    <xsl:for-each select="$available_items[position() &lt;= $resultsMaxItems]">
1315
                                                        <xsl:value-of select="items:itemcallnumber"/>
1316
                                                        <xsl:if test="position()!=last()"><xsl:text>, </xsl:text></xsl:if>
1317
                                                    </xsl:for-each>
1318
                                                    <xsl:if test="count(key('item-by-status-and-branch-holding', concat(items:status, ' ', items:holdingbranch)))>$resultsMaxItems"><xsl:text>, ..</xsl:text></xsl:if>
1319
                                                </span>
1320
                                            </span>
1302
                                       </xsl:if>
1321
                                       </xsl:if>
1303
                                       <xsl:choose>
1322
                                       <xsl:choose>
1304
                                           <xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when>
1323
                                           <xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when>
Lines 1335-1341 Link Here
1335
                                <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1354
                                <xsl:if test="items:itemcallnumber != '' and items:itemcallnumber and $OPACItemLocation='callnum'">
1336
                                    <span class="CallNumberAndLabel">
1355
                                    <span class="CallNumberAndLabel">
1337
                                        <span class="LabelCallNumber">Call number: </span>
1356
                                        <span class="LabelCallNumber">Call number: </span>
1338
                                        <span class="CallNumber"><xsl:value-of select="items:itemcallnumber"/><xsl:if test="count(key('item-by-substatus-and-branch', concat(items:substatus, ' ', items:homebranch)))>1"><xsl:text>, ..</xsl:text></xsl:if></span>
1357
                                        <span class="CallNumber">
1358
                                            <xsl:for-each select="$reference_items[position() &lt;= $resultsMaxItems]">
1359
                                                <xsl:value-of select="items:itemcallnumber"/>
1360
                                                <xsl:if test="position()!=last()"><xsl:text>, </xsl:text></xsl:if>
1361
                                            </xsl:for-each>
1362
                                            <xsl:if test="count(key('item-by-substatus-and-branch', concat(items:substatus, ' ', items:homebranch)))>$resultsMaxItems"><xsl:text>, ..</xsl:text></xsl:if>
1363
                                        </span>
1339
                                    </span>
1364
                                    </span>
1340
                                </xsl:if>
1365
                                </xsl:if>
1341
                                <xsl:choose><xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when><xsl:otherwise><xsl:text>, </xsl:text></xsl:otherwise></xsl:choose>
1366
                                <xsl:choose><xsl:when test="position()=last()"><xsl:text>. </xsl:text></xsl:when><xsl:otherwise><xsl:text>, </xsl:text></xsl:otherwise></xsl:choose>
1342
- 

Return to bug 26302