https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=37061
--- Comment #19 from Martin Renvoize (ashimema) <[email protected]> --- Created attachment 211556 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=211556&action=edit Bug 37061: Build the link field of a component part with the template of the link field The data of a host record that is copied to the link field of a new component part (773 for MARC21, 461 for UNIMARC) was hard coded in Koha::Biblio->generate_marc_host_field. Apply the template of the link field, a MARC modification template (see GetLinkFieldTemplate), to the generated field, with the host record as the donor. The template reads the host and changes the link field, for example: update_field 773$t {245a|nonfiling|trim|ucfirst} update_field 773$h {300a} {300e} The default link field is always generated first, and the subfields that identify the host are never changed, so the link between the records stays reliable whatever the template: the $w with the control number, the $7, the $0 and $9 and, with the easy analytics workflow, the barcode in the $o, and the indicators. The template cannot delete the field either. If there is no template, or it does not give a link field, the generated field is used. The link fields that can be built and their fixed subfields are defined in one place, Koha::Biblio->host_link_field_definition, so that other linking fields can be added. To test: 1. prove t/db_dependent/Koha/Biblio.t -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list -- [email protected] To unsubscribe send an email to [email protected] website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
