]> git.evergreen-ils.org Git - Evergreen.git/commit
LP#1950394: isolate attribute extraction of metarecord
authorGalen Charlton <gmc@equinoxOLI.org>
Tue, 9 Nov 2021 23:22:07 +0000 (18:22 -0500)
committerJason Stephenson <jason@sigio.com>
Tue, 15 Mar 2022 18:13:55 +0000 (14:13 -0400)
commitcaef876670021fec21dd2e3a95951fd71c25233a
tree08d6f3fa73f2182296ced6c0438f8fad4f48c824
parentef12f9565c8afb5b2502f6881c440782457c1155
LP#1950394: isolate attribute extraction of metarecord

This patch ensures that calling the Template Toolkit block
get_marc_attrs() on the metarecord's lead record's MARCXML
does not interfere with attributes already parsed from the
current bib's MARCXML on the record summary page in the Bootstrap
OPAC.

This fixes an issue where electronic resource links could fail to
be displayed under the following conditions:

- the MARC record has an 856 field with ind1 = 4 and ind2 = 0 or 1
  and is NOT a located URI
- the bib is part of a metarecord set with at least one other member
- the master record in the metarecord set does not have 856 fields

To test
-------
[1] Create a setup where two bibs are in the same metarecord set, one
    with 856 fields and one without. Arrange that the one without
    856 fields is the lead record in the metarecord.
[2] View the one that has 856 fields in the Bootstrap OPAC's record
    summary page. Note that the electronic resource links do not
    appear.
[3] Apply the patch and repeat step 2. This time, the links should
    appear.

Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Signed-off-by: Jason Stephenson <jason@sigio.com>
Open-ILS/src/templates-bootstrap/opac/parts/record/summary.tt2