From 65e0fba94b8e0f16de20214f6f2c89c2327fb3d0 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Wed, 29 Oct 2014 16:24:49 -0300 Subject: [PATCH] Bug 13164: Incorrect ISSN visualization on the normal view if invalid/cancelled ISSN present 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 Works as described on an UNIMARC DB. Mimics what's done for ISBN field. Signed-off-by: Kyle M Hall Signed-off-by: Tomas Cohen Arazi --- .../en/xslt/MARC21slim2intranetDetail.xsl | 24 +++++++++++----- .../en/xslt/NORMARCslim2intranetDetail.xsl | 24 +++++++++++----- .../en/xslt/UNIMARCslim2intranetDetail.xsl | 27 ++++++++++-------- .../en/xslt/MARC21slim2OPACDetail.xsl | 24 +++++++++++----- .../en/xslt/NORMARCslim2OPACDetail.xsl | 24 +++++++++++----- .../en/xslt/UNIMARCslim2OPACDetail.xsl | 28 ++++++++++--------- 6 files changed, 98 insertions(+), 53 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl index e7bf6d1a2d..6711f9ddb5 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl +++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl @@ -400,13 +400,23 @@ - - ISSN: - - - .; - - + + + ISSN: + + + + + + . + + + ; + + + + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetDetail.xsl index 3271e5b93a..150a29afd8 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetDetail.xsl +++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetDetail.xsl @@ -316,13 +316,23 @@ - - ISSN: - - - .; - - + + + ISSN: + + + + + + . + + + ; + + + + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl index 552385e30d..61d80854ce 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl +++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl @@ -159,19 +159,22 @@ - + +
  • - ISSN: - - - - - . - - - ; - - + ISSN: + + + + + + . + + + ; + + +
  • diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl index 353a96ea21..fe8daacfd5 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl +++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl @@ -441,13 +441,23 @@
    - - ISSN: - - - .; - - + + + ISSN: + + + + + + . + + + ; + + + + + diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACDetail.xsl index 62e004da8c..7a8e5ce41e 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACDetail.xsl +++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACDetail.xsl @@ -352,13 +352,23 @@ - - ISSN: - - - .; - - + + + ISSN: + + + + + + . + + + ; + + + + + diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl index f7d19845a9..40eac3aabc 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl +++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl @@ -207,19 +207,21 @@ - - - ISSN: - - - - - . - - - ; - - + + + ISSN: + + + + + + . + + + ; + + + -- 2.39.2