]> git.koha-community.org Git - koha.git/commit
Bug 16556 - KohaToMarcMapped columns sharing same field with biblio(item)number are...
authorOlli-Antti Kivilahti <olli-antti.kivilahti@jns.fi>
Thu, 19 May 2016 14:12:06 +0000 (17:12 +0300)
committerJulian Maurice <julian.maurice@biblibre.com>
Fri, 16 Sep 2016 10:01:31 +0000 (12:01 +0200)
commit1096c177a79a55ad134466efd7e2c65605e7714c
tree787ac05c974607005b51ce9297359a7dc6de5201
parentb098500c713494e18c571314ec34b74273821f92
Bug 16556 - KohaToMarcMapped columns sharing same field with biblio(item)number are removed.

REPLICATE ISSUE:

1. Map biblio.frameworkcode to 999$b
2. Map biblio.biblionumber to 999$c
3. Add a record with something in 999$b
4. 999$b is removed by C4::Biblio::AddBiblio()

After this patch, the field used by biblio.biblionumber or biblioitems.biblioitemnumber
is not removed and created anew, thus dropping all existing additions.

There is no point in dropping the field in any case, since we can just replace
the existing subfields in-place with no need to recreate the whole field.

UNIT TESTS INCLUDED

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit a9eb4005811882da0eb5e20b52861a3c85556dff)
(cherry picked from commit 26ccb6a4809154368e02e5c147414fc7a19d31be)
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
C4/Biblio.pm
t/Biblio2.t [new file with mode: 0644]