test plan :
- Apply patch
- Find a record with a B214
- Check on both Opac-Details and Opac-Result that the field is
displayed.
- Do the same checks on catalogue/search results and catalogue/details
in Staff interface.
- Add a 210 field to the record (legacy)
- It should be displayed as well
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Tomás Cohen Arazi <tomascohen@theke.io>
Bug 23290 explicitly disabled entity expansion during XML parsing for security reasons.
However, many XSLTs define the following entity:
<!ENTITY nbsp " " >
They don't use the entity  , but its presence could lead to confusion.
Signed-off-by: Eden Bacani <eden.bacani@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
In all XSLT for record display, fields are created with <span class="results_summary> except in UNIMARC intranet where there is just <li>.
This allows a better CSS customisation and closer code in files for OPAC and intranet.
Actually li gets diplayed with a dot at each line, we don't want this.
Test plan :
1) For each modified file run 'xsltproc file.xsl' and see there is no
error
2) Use default XSLT in all system preferences
3) Perform a search and check display with and without patch
4) Click on a record to see details and check display with and without patch
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
In UNIMARC default configuration the 001 is linked to biblio.biblionumber.
In some XSLT files, 090$a is used.
This is by default biblioitems.biblionumber so it usually works but it may not be the same and var biblionumber is used to create hyperlinks to record detail page.
Test plan :
1) Use UNIMARC database
2) Set default in all XSLT system preferences
3) At OPAC, perform a search and click on a result
4) Check displayed page shows the correct biblio record
5) Same at intranet
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Tested on clean UNIMARC install.
Before insert new records: "alter table biblioitems AUTO_INCREMENT = 5"
Added two records, with result:
+--------------+------------------+
| biblionumber | biblioitemnumber |
+--------------+------------------+
| 1 | 5 |
| 2 | 6 |
+--------------+------------------+
Without patch, OPAC results shows for first record
http://opac/cgi-bin/koha/opac-detail.pl?biblionumber=5, Wrong!
with patch result is correct
Works, no errors
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Bug 14716 added a call to encode-uri() and namespace str. This
namespace declaration is sometimes missing in UNIMARC default XSLT
files.
This patch adds namespace declaration also where encode-uri is not used
because it may be used in the future. And those files are the base for
home made custom files.
Test plan :
1) Use a UNIMARC DB
2) Use default in all XSLT sysprefs
3) Apply patch
4) Perform a search on OPAC
5) Check display is OK
6) Click on a record for detail page
7) Check display is OK
8) Perform a search on staff interface
9) Check display is OK
10) Click on a record for detail page
11) Check display is OK
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Currently, 020$z (and 010$z fr UNIMARC) occurences are not shown, but the XSLT logic
used introduces punctuation characters for those $z occurences.
This patch adds a check for the existence of subfield a, and only loops
on $a subfields.
To test:
- Create/have a record with 020$z (or 010$z on UNIMARC) but no 020$a (no 010$a on UNIMARC).
- Open the detail page for the record (on both OPAC and staff).
=> FAIL: the ISBN label and ';' and '.' characters incorrectly shown.
- Repeat mixing with 020$a occurences to notice the bug.
- Apply the patch, reload
=> SUCCES: ISBN label shows only on the presence of a $a, and $z are skipped.
no matter how many ISBN fields you add.
- Sign off :-D
Regards
To+
http://bugs.koha-community.org/show_bug.cgi?id=12901
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Currently, 022$z (and 011$z for UNIMARC) occurences are not shown, but the XSLT
logic used introduces punctuation characters for those $z occurences.
This patch adds a check for the existence of subfield a, and only loops
on $a subfields.
To test:
- Create/have a record with 022$z (or 011$z on UNIMARC) but no 022$a (no 011$a on UNIMARC).
- Open the detail page for the record (on both OPAC and staff).
=> FAIL: the ISSN label and ';' and '.' characters incorrectly shown.
- Repeat mixing with 022$a occurences to notice the bug.
- Apply the patch, reload
=> SUCCES: ISSN label shows only on the presence of a $a, and $z are skipped.
no matter how many ISSN fields you add.
- Sign off :-D
Regards
To+
Signed-off-by: Frederic Demians <f.demians@tamil.fr>
Works as described on an UNIMARC DB. Mimics what's done for ISBN field.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
UNIMARCslim2OPACDetail.xsl and UNIMARCslim2intranetDetail.xsl contained
references to 780 and 785 fields, that exist in MARC21 but not in UNIMARC.
This patch remove the code related to 780 and 785 fields. No effect should
be visible.
To test : in a UNIMARC Koha
1. Be sure that OPACXSLTDetailsDisplay, OPACXSLTResultsDisplay,
XSLTDetailsDisplay and XSLTResultsDisplay sysprefs are set to "default"
2. Apply the patch
3. Search some records in staff interface : the list view and the detail
view must be exacty the same as before you apply the patch.
4. search some records in OPAC : the list view and the detail view must
be exactly the same as before you apply the patch.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Comment: No diplay change, no koha-qa errors.
Removes what can't be displayed.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Checked detail pages in OPAC and intranet still display correctly
and without errors.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
As in Bug 6278, this patch replace ">at<" with ">a_t<"
so not to mislead translators. Found more cases that
initial description.
To test:
1) Check that problem exists and only on xslt files,
using your preferred language
egrep -B10 "^msgid \"at\"" misc/translator/po/xx-YY-i-staff-t*
2) Apply the patch
3) Update translation file
(cd misc/translator; perl translate update xx-YY)
4) Verify the problem is gone, repeat 1
5) If you like verify new entries in PO file
egrep -B15 "^msgid \"a_t\"" misc/translator/po/xx-YY-i-staff-t*
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested this with field 780 and running a Dutch translation.
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Passed-QA-by: Mason James <mtj@kohaaloha.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Because we are embedding the results of XSLT stylesheets in HTML, we
need to output HTML instead of XML. Outputting XML results in
non-standard-compliant (or at least non-Firefox-compliant) markup.
To test:
View a variety of XSLT-rendered pages on the OPAC and intranet, and
confirm that all look as expected.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
dealing with some BNF/SUDOC invalid utf-8 (in title, the removed fields are used to mark non-sorted words)
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
I can't test this works ok for UNIMARC, but it does not cause any
problems with the translation scripts or MARC21 so signing off
Add an option to the OPAC to display the URI that is stored in the 856u field
as an image instead of a text link. This would be implemented in the OPAC XSLT
style sheets for the Results and Details pages, and would require that the
corresponding OPAC XSLT option be set.
This enhancement is designed to enable the staff to catalog images, then have
them appear on the resulting pages in the OPAC when searching. Clicking on the
image would open it full size. If the image option is in use, then the default
link text would be disabled. Custom text would still appear if entered in the
"URLLinkText" option.
Add system preference "Display856uAsImage" with options of Results page,
Details page, Both Results and Details pages, Neither Results or Details page.
Notes for documentation manager:
There are two system preferences added for this enhancement:
OPACDisplay856uAsImage and Display856uAsImage. These appear on the OPAC and
Staff Client screens under the System Preferences.
The preference can be set to one of four options:
Both Details and Results pages
Details page only
Neither Details or Results pages
Results page only
In addition to this option being set, the corresponding XSLT option must be
turned on. Also, the corresponding 856q field must have a valid MIME image
extension (e.g., "jpg") or MIME image type (i.e. starting with "image/"), or the
generic indicator "img" entered in the field.
As of 14 March 2011 the UNIMARC xslt display files also require a "0" in the
second indicator location of the 856u field for the links to be activated. This
is not true for the MARC21 display files.
When all of the requirements are met, an image file will be displayed instead of
the standard link text. Clicking on the image will open it in the same way as
clicking on the link text.
Rebased and three original patches squashed into one on 30 March 2011 by Jared
Camins-Esakov.
Signed-off-by: Jared Camins-Esakov <jcamins@bywatersolutions.com>
Signed-off-by: Doug Dearden <dearden@sarsf.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Prevent the generation of empty label spans for various
bib details fields. A construct like
<span class="results_summary"><span class="label" />contents note</span>
is consistently misinterpreted in many web browsers, leading to
CSS oddities. See the bug for more details.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
The unAPI link is now added only in opac-detail.tmpl. More than
one unAPI link in the same page was causing a bit of indigestion
for Zotero, which interprets multiple unAPI links as specifying
more than one resource on a given page.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
- Add two syspref:
- OPACXSLTResultsDisplay
- OPACXSLDetailsDispay
- Add them to .pref files and dispatch them beetween OPAC and Search
tab.
- Upgrade DB version to 3.2 .113
- Fix something wrong in UNIMARCslim2intranetDetail.xsl
- Display OPAC result and detail pages using those syspref.
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
- the XSLTParse4Display sub now has a new parameter : the interface (intranet or opac)
- the XSLTdisplay sysprefs is common to staff & opac (Auth.pm)
- added UNIMARC xslt in intranet templates (modified to deal with staff/opac differences)