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

(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslimUtils.xsl (-59 / +44 lines)
Lines 31-43 Link Here
31
  <xsl:template name="tag_210-214">
31
  <xsl:template name="tag_210-214">
32
    <xsl:choose>
32
    <xsl:choose>
33
      <xsl:when test="marc:datafield[@tag=210] and marc:datafield[@tag=214]">
33
      <xsl:when test="marc:datafield[@tag=210] and marc:datafield[@tag=214]">
34
	<xsl:call-template name="tag_214" />
34
        <xsl:call-template name="tag_214" />
35
      </xsl:when>
35
      </xsl:when>
36
      <xsl:when test="marc:datafield[@tag=214]">
36
      <xsl:when test="marc:datafield[@tag=214]">
37
	<xsl:call-template name="tag_214" />
37
        <xsl:call-template name="tag_214" />
38
      </xsl:when>
38
      </xsl:when>
39
      <xsl:when test="marc:datafield[@tag=210]">
39
      <xsl:when test="marc:datafield[@tag=210]">
40
	<xsl:call-template name="tag_210" />
40
        <xsl:call-template name="tag_210" />
41
      </xsl:when>
41
      </xsl:when>
42
    </xsl:choose>
42
    </xsl:choose>
43
  </xsl:template>
43
  </xsl:template>
Lines 46-62 Link Here
46
    <span class="results_summary publication">
46
    <span class="results_summary publication">
47
      <span class="label">Publication: </span>
47
      <span class="label">Publication: </span>
48
      <xsl:for-each select="marc:datafield[@tag=210]">
48
      <xsl:for-each select="marc:datafield[@tag=210]">
49
        <xsl:if test="not (position() = 1)">
49
        <xsl:if test="not(position() = 1)">
50
          <br/>
50
          <br/>
51
        </xsl:if>
51
        </xsl:if>
52
        <span class="valeur">
52
        <span class="value">
53
          <xsl:call-template name="addClassRtl" />
53
          <xsl:call-template name="addClassRtl" />
54
          <xsl:for-each select="marc:subfield">
54
          <xsl:for-each select="marc:subfield[@code='a' or @code='b' or @code='c' or @code='d' or @code='g']">
55
            <xsl:choose>
55
            <xsl:choose>
56
              <xsl:when test="@code='a'">
56
              <xsl:when test="@code='a'">
57
                <xsl:value-of select="."/>
57
                <xsl:value-of select="."/>
58
                <xsl:if test="position() != last()">
58
                <xsl:if test="position() != last()">
59
                  <xsl:text>: </xsl:text>
59
                  <xsl:text> : </xsl:text>
60
                </xsl:if>
60
                </xsl:if>
61
              </xsl:when>
61
              </xsl:when>
62
              <xsl:when test="@code='b'">
62
              <xsl:when test="@code='b'">
Lines 66-80 Link Here
66
                </xsl:if>
66
                </xsl:if>
67
              </xsl:when>
67
              </xsl:when>
68
              <xsl:when test="@code='c' or @code='g'">
68
              <xsl:when test="@code='c' or @code='g'">
69
                <xsl:if test="position()>1">
70
                  <xsl:text> : </xsl:text>
71
                </xsl:if>
72
                <a>
69
                <a>
73
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?idx=pb&amp;q=<xsl:value-of select="."/>
70
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=pb:<xsl:value-of select="str:encode-uri(., true())"/></xsl:attribute>
74
                  </xsl:attribute>
71
                  <xsl:attribute name="title">Search for publisher</xsl:attribute>
75
                  <xsl:attribute name="title"> Search for publisher "<xsl:value-of select="."/>
76
                  <xsl:text>"</xsl:text>
77
                  </xsl:attribute>
78
                  <xsl:value-of select="."/>
72
                  <xsl:value-of select="."/>
79
                </a>
73
                </a>
80
                <xsl:if test="position() != last()">
74
                <xsl:if test="position() != last()">
Lines 100-123 Link Here
100
      <span class="results_summary publication">
94
      <span class="results_summary publication">
101
        <span class="label">
95
        <span class="label">
102
          <xsl:choose>
96
          <xsl:choose>
103
            <xsl:when test="@ind2=1">Production:
97
            <xsl:when test="@ind2=1">Production: </xsl:when>
104
	    </xsl:when>
98
            <xsl:when test="@ind2=2">Distribution: </xsl:when>
105
            <xsl:when test="@ind2=2">Distribution:
99
            <xsl:when test="@ind2=3">Manufacture: </xsl:when>
106
	    </xsl:when>
107
            <xsl:when test="@ind2=3">Manufacture:
108
	    </xsl:when>
109
            <xsl:when test="@ind2=4">
100
            <xsl:when test="@ind2=4">
110
              <xsl:choose>
101
              <xsl:choose>
111
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='C'">Copyright date:
102
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='C'">Copyright date: </xsl:when>
112
		</xsl:when>
103
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='P'">Protection date: </xsl:when>
113
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='P'">Protection date:
104
                <xsl:otherwise>Copyright date / protection date: </xsl:otherwise>
114
		</xsl:when>
115
                <xsl:otherwise>Copyright date / protection date:
116
		</xsl:otherwise>
117
              </xsl:choose>
105
              </xsl:choose>
118
            </xsl:when>
106
            </xsl:when>
119
            <xsl:otherwise>Publication:
107
            <xsl:otherwise>Publication: </xsl:otherwise>
120
	    </xsl:otherwise>
121
          </xsl:choose>
108
          </xsl:choose>
122
        </span>
109
        </span>
123
        <span>
110
        <span>
Lines 127-148 Link Here
127
              <xsl:when test="@code='a'">
114
              <xsl:when test="@code='a'">
128
                <xsl:value-of select="."/>
115
                <xsl:value-of select="."/>
129
                <xsl:if test="position() != last()">
116
                <xsl:if test="position() != last()">
130
                  <xsl:text>: </xsl:text>
117
                  <xsl:text> : </xsl:text>
131
                </xsl:if>
118
                </xsl:if>
132
              </xsl:when>
119
              </xsl:when>
133
              <xsl:when test="@code='b'">
120
              <xsl:when test="@code='b'">
134
                <xsl:value-of select="."/>
121
                <xsl:value-of select="."/>
135
                <xsl:if test="not(position()=1)">
122
                <xsl:if test="position() != last()">
136
                  <xsl:text>, </xsl:text>
123
                  <xsl:text>, </xsl:text>
137
                </xsl:if>
124
                </xsl:if>
138
              </xsl:when>
125
              </xsl:when>
139
              <xsl:when test="@code='c'">
126
              <xsl:when test="@code='c'">
140
                <a>
127
                <a>
141
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?idx=pb&amp;q=<xsl:value-of select="."/>
128
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=pb:<xsl:value-of select="str:encode-uri(., true())"/></xsl:attribute>
142
                  </xsl:attribute>
129
                  <xsl:attribute name="title">Search for publisher</xsl:attribute>
143
                  <xsl:attribute name="title"> Search for publisher "<xsl:value-of select="."/>
144
                  <xsl:text>"</xsl:text>
145
                  </xsl:attribute>
146
                  <xsl:value-of select="."/>
130
                  <xsl:value-of select="."/>
147
                </a>
131
                </a>
148
              </xsl:when>
132
              </xsl:when>
Lines 174-190 Link Here
174
  <xsl:template name="tag_214_s">
158
  <xsl:template name="tag_214_s">
175
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='s']">
159
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='s']">
176
      <span class="results_summary tag_214_s">
160
      <span class="results_summary tag_214_s">
177
	<span class="label">Printing and/or Publishing Information Transcribed as Found in the Colophon: </span>
161
        <span class="label">Printing and/or Publishing Information Transcribed as Found in the Colophon: </span>
178
	<xsl:for-each select="marc:datafield[@tag=214]">
162
        <xsl:for-each select="marc:datafield[@tag=214]/marc:subfield[@code='s']">
179
	  <xsl:value-of select="marc:subfield[@code='s']"/>
163
          <xsl:value-of select="."/>
180
	  <xsl:choose>
164
          <xsl:choose>
181
	    <xsl:when test="position()=last()">
165
            <xsl:when test="position()=last()">
182
	      <xsl:text>.</xsl:text>
166
              <xsl:text>.</xsl:text>
183
	    </xsl:when>
167
            </xsl:when>
184
	    <xsl:otherwise><xsl:text>, </xsl:text>
168
            <xsl:otherwise>
185
	    </xsl:otherwise>
169
              <xsl:text>, </xsl:text>
186
	  </xsl:choose>
170
            </xsl:otherwise>
187
	</xsl:for-each>
171
          </xsl:choose>
172
        </xsl:for-each>
188
      </span>
173
      </span>
189
    </xsl:if>
174
    </xsl:if>
190
  </xsl:template>
175
  </xsl:template>
Lines 192-209 Link Here
192
  <xsl:template name="tag_214_r">
177
  <xsl:template name="tag_214_r">
193
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='r']">
178
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='r']">
194
      <span class="results_summary tag_214_r">
179
      <span class="results_summary tag_214_r">
195
	<span class="label">Printing and/or Publishing Information Transcribed as Found in the Main Source of
180
        <span class="label">Printing and/or Publishing Information Transcribed as Found in the Main Source of Information: </span>
196
	Information: </span>
181
        <xsl:for-each select="marc:datafield[@tag=214]/marc:subfield[@code='r']">
197
	<xsl:for-each select="marc:datafield[@tag=214]">
182
          <xsl:value-of select="."/>
198
	  <xsl:value-of select="marc:subfield[@code='r']"/>
183
          <xsl:choose>
199
	  <xsl:choose>
184
            <xsl:when test="position()=last()">
200
	    <xsl:when test="position()=last()">
185
              <xsl:text>.</xsl:text>
201
	      <xsl:text>.</xsl:text>
186
            </xsl:when>
202
	    </xsl:when>
187
            <xsl:otherwise>
203
	    <xsl:otherwise><xsl:text>, </xsl:text>
188
              <xsl:text>, </xsl:text>
204
	    </xsl:otherwise>
189
            </xsl:otherwise>
205
	  </xsl:choose>
190
          </xsl:choose>
206
	</xsl:for-each>
191
        </xsl:for-each>
207
      </span>
192
      </span>
208
    </xsl:if>
193
    </xsl:if>
209
  </xsl:template>
194
  </xsl:template>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslimUtils.xsl (-72 / +59 lines)
Lines 192-204 Link Here
192
  <xsl:template name="tag_210-214">
192
  <xsl:template name="tag_210-214">
193
    <xsl:choose>
193
    <xsl:choose>
194
      <xsl:when test="marc:datafield[@tag=210] and marc:datafield[@tag=214]">
194
      <xsl:when test="marc:datafield[@tag=210] and marc:datafield[@tag=214]">
195
	<xsl:call-template name="tag_214" />
195
        <xsl:call-template name="tag_214" />
196
      </xsl:when>
196
      </xsl:when>
197
      <xsl:when test="marc:datafield[@tag=214]">
197
      <xsl:when test="marc:datafield[@tag=214]">
198
	<xsl:call-template name="tag_214" />
198
        <xsl:call-template name="tag_214" />
199
      </xsl:when>
199
      </xsl:when>
200
      <xsl:when test="marc:datafield[@tag=210]">
200
      <xsl:when test="marc:datafield[@tag=210]">
201
	<xsl:call-template name="tag_210" />
201
        <xsl:call-template name="tag_210" />
202
      </xsl:when>
202
      </xsl:when>
203
    </xsl:choose>
203
    </xsl:choose>
204
  </xsl:template>
204
  </xsl:template>
Lines 207-253 Link Here
207
    <span class="results_summary publication">
207
    <span class="results_summary publication">
208
      <span class="label">Publication: </span>
208
      <span class="label">Publication: </span>
209
      <xsl:for-each select="marc:datafield[@tag=210]">
209
      <xsl:for-each select="marc:datafield[@tag=210]">
210
	<xsl:if test="not (position() = 1)">
210
        <xsl:if test="not(position() = 1)">
211
          <br/>
211
          <br/>
212
	</xsl:if>
212
        </xsl:if>
213
	<span class="valeur">
213
        <span class="value">
214
          <xsl:call-template name="addClassRtl" />
214
          <xsl:call-template name="addClassRtl" />
215
          <xsl:for-each select="marc:subfield">
215
          <xsl:for-each select="marc:subfield[@code='a' or @code='b' or @code='c' or @code='d' or @code='g']">
216
            <xsl:choose>
216
            <xsl:choose>
217
              <xsl:when test="@code='a'">
217
              <xsl:when test="@code='a'">
218
		<xsl:value-of select="."/>
218
                <xsl:value-of select="."/>
219
		<xsl:if test="position() != last()">
219
                <xsl:if test="position() != last()">
220
                  <xsl:text>: </xsl:text>
220
                  <xsl:text> : </xsl:text>
221
		</xsl:if>
221
                </xsl:if>
222
              </xsl:when>
222
              </xsl:when>
223
              <xsl:when test="@code='b'">
223
              <xsl:when test="@code='b'">
224
		<xsl:value-of select="."/>
224
                <xsl:value-of select="."/>
225
		<xsl:if test="position() != last()">
225
                <xsl:if test="position() != last()">
226
                  <xsl:text>, </xsl:text>
226
                  <xsl:text>, </xsl:text>
227
		</xsl:if>
227
                </xsl:if>
228
              </xsl:when>
228
              </xsl:when>
229
              <xsl:when test="@code='c' or @code='g'">
229
              <xsl:when test="@code='c' or @code='g'">
230
		<a>
230
                <a>
231
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?idx=pb&amp;q=<xsl:value-of select="."/>
231
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=pb:<xsl:value-of select="str:encode-uri(., true())"/></xsl:attribute>
232
                  </xsl:attribute>
232
                  <xsl:attribute name="title">Search for publisher</xsl:attribute>
233
                  <xsl:attribute name="title"> Search for publisher "<xsl:value-of select="."/>
234
                  <xsl:text>"</xsl:text>
235
                  </xsl:attribute>
236
                  <xsl:value-of select="."/>
233
                  <xsl:value-of select="."/>
237
		</a>
234
                </a>
238
		<xsl:if test="position() != last()">
235
                <xsl:if test="position() != last()">
239
                  <xsl:text>, </xsl:text>
236
                  <xsl:text>, </xsl:text>
240
		</xsl:if>
237
                </xsl:if>
241
              </xsl:when>
238
              </xsl:when>
242
              <xsl:when test="@code='d'">
239
              <xsl:when test="@code='d'">
243
		<xsl:value-of select="."/>
240
                <xsl:value-of select="."/>
244
		<xsl:if test="position() != last()">
241
                <xsl:if test="position() != last()">
245
                  <xsl:text>, </xsl:text>
242
                  <xsl:text>, </xsl:text>
246
		</xsl:if>
243
                </xsl:if>
247
              </xsl:when>
244
              </xsl:when>
248
            </xsl:choose>
245
            </xsl:choose>
249
          </xsl:for-each>
246
          </xsl:for-each>
250
	</span>
247
        </span>
251
      </xsl:for-each>
248
      </xsl:for-each>
252
    </span>
249
    </span>
253
  </xsl:template>
250
  </xsl:template>
Lines 258-281 Link Here
258
      <span class="results_summary publication">
255
      <span class="results_summary publication">
259
        <span class="label">
256
        <span class="label">
260
          <xsl:choose>
257
          <xsl:choose>
261
            <xsl:when test="@ind2=1">Production:
258
            <xsl:when test="@ind2=1">Production: </xsl:when>
262
	    </xsl:when>
259
            <xsl:when test="@ind2=2">Distribution: </xsl:when>
263
            <xsl:when test="@ind2=2">Distribution:
260
            <xsl:when test="@ind2=3">Manufacture: </xsl:when>
264
	    </xsl:when>
265
            <xsl:when test="@ind2=3">Manufacture:
266
	    </xsl:when>
267
            <xsl:when test="@ind2=4">
261
            <xsl:when test="@ind2=4">
268
              <xsl:choose>
262
              <xsl:choose>
269
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='C'">Copyright date:
263
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='C'">Copyright date: </xsl:when>
270
		</xsl:when>
264
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='P'">Protection date: </xsl:when>
271
                <xsl:when test="substring(marc:subfield[@code='d'],1,1)='P'">Protection date:
265
                <xsl:otherwise>Copyright date / protection date: </xsl:otherwise>
272
		</xsl:when>
273
                <xsl:otherwise>Copyright date / protection date:
274
		</xsl:otherwise>
275
              </xsl:choose>
266
              </xsl:choose>
276
            </xsl:when>
267
            </xsl:when>
277
            <xsl:otherwise>Publication:
268
            <xsl:otherwise>Publication: </xsl:otherwise>
278
	    </xsl:otherwise>
279
          </xsl:choose>
269
          </xsl:choose>
280
        </span>
270
        </span>
281
        <span>
271
        <span>
Lines 285-306 Link Here
285
              <xsl:when test="@code='a'">
275
              <xsl:when test="@code='a'">
286
                <xsl:value-of select="."/>
276
                <xsl:value-of select="."/>
287
                <xsl:if test="position() != last()">
277
                <xsl:if test="position() != last()">
288
                  <xsl:text>: </xsl:text>
278
                  <xsl:text> : </xsl:text>
289
                </xsl:if>
279
                </xsl:if>
290
              </xsl:when>
280
              </xsl:when>
291
              <xsl:when test="@code='b'">
281
              <xsl:when test="@code='b'">
292
                <xsl:value-of select="."/>
282
                <xsl:value-of select="."/>
293
                <xsl:if test="not(position()=1)">
283
                <xsl:if test="position() != last()">
294
                  <xsl:text>, </xsl:text>
284
                  <xsl:text>, </xsl:text>
295
                </xsl:if>
285
                </xsl:if>
296
              </xsl:when>
286
              </xsl:when>
297
              <xsl:when test="@code='c'">
287
              <xsl:when test="@code='c'">
298
                <a>
288
                <a>
299
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?idx=pb&amp;q=<xsl:value-of select="."/>
289
                  <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=pb:<xsl:value-of select="str:encode-uri(., true())"/></xsl:attribute>
300
                  </xsl:attribute>
290
                  <xsl:attribute name="title">Search for publisher</xsl:attribute>
301
                  <xsl:attribute name="title"> Search for publisher "<xsl:value-of select="."/>
302
                  <xsl:text>"</xsl:text>
303
                  </xsl:attribute>
304
                  <xsl:value-of select="."/>
291
                  <xsl:value-of select="."/>
305
                </a>
292
                </a>
306
              </xsl:when>
293
              </xsl:when>
Lines 332-348 Link Here
332
  <xsl:template name="tag_214_s">
319
  <xsl:template name="tag_214_s">
333
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='s']">
320
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='s']">
334
      <span class="results_summary tag_214_s">
321
      <span class="results_summary tag_214_s">
335
	<span class="label">Printing and/or Publishing Information Transcribed as Found in the Colophon: </span>
322
        <span class="label">Printing and/or Publishing Information Transcribed as Found in the Colophon: </span>
336
	<xsl:for-each select="marc:datafield[@tag=214]">
323
        <xsl:for-each select="marc:datafield[@tag=214]/marc:subfield[@code='s']">
337
	  <xsl:value-of select="marc:subfield[@code='s']"/>
324
          <xsl:value-of select="."/>
338
	  <xsl:choose>
325
          <xsl:choose>
339
	    <xsl:when test="position()=last()">
326
            <xsl:when test="position()=last()">
340
	      <xsl:text>.</xsl:text>
327
              <xsl:text>.</xsl:text>
341
	    </xsl:when>
328
            </xsl:when>
342
	    <xsl:otherwise><xsl:text>, </xsl:text>
329
            <xsl:otherwise>
343
	    </xsl:otherwise>
330
              <xsl:text>, </xsl:text>
344
	  </xsl:choose>
331
            </xsl:otherwise>
345
	</xsl:for-each>
332
          </xsl:choose>
333
        </xsl:for-each>
346
      </span>
334
      </span>
347
    </xsl:if>
335
    </xsl:if>
348
  </xsl:template>
336
  </xsl:template>
Lines 350-367 Link Here
350
  <xsl:template name="tag_214_r">
338
  <xsl:template name="tag_214_r">
351
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='r']">
339
    <xsl:if test="marc:datafield[@tag=214]/marc:subfield[@code='r']">
352
      <span class="results_summary tag_214_r">
340
      <span class="results_summary tag_214_r">
353
	<span class="label">Printing and/or Publishing Information Transcribed as Found in the Main Source of
341
        <span class="label">Printing and/or Publishing Information Transcribed as Found in the Main Source of Information: </span>
354
	formation: </span>
342
        <xsl:for-each select="marc:datafield[@tag=214]/marc:subfield[@code='r']">
355
	<xsl:for-each select="marc:datafield[@tag=214]">
343
          <xsl:value-of select="."/>
356
	  <xsl:value-of select="marc:subfield[@code='r']"/>
344
          <xsl:choose>
357
	  <xsl:choose>
345
            <xsl:when test="position()=last()">
358
	    <xsl:when test="position()=last()">
346
              <xsl:text>.</xsl:text>
359
	      <xsl:text>.</xsl:text>
347
            </xsl:when>
360
	    </xsl:when>
348
            <xsl:otherwise>
361
	    <xsl:otherwise><xsl:text>, </xsl:text>
349
              <xsl:text>, </xsl:text>
362
	    </xsl:otherwise>
350
            </xsl:otherwise>
363
	  </xsl:choose>
351
          </xsl:choose>
364
	</xsl:for-each>
352
        </xsl:for-each>
365
      </span>
353
      </span>
366
    </xsl:if>
354
    </xsl:if>
367
  </xsl:template>
355
  </xsl:template>
368
- 

Return to bug 30430