LP#1145213: improvements to record merge
authorRogan Hamby <rogan.hamby@gmail.com>
Wed, 9 Aug 2017 12:50:41 +0000 (08:50 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Tue, 7 Nov 2017 20:51:40 +0000 (15:51 -0500)
commitd2c8443068061879747750df023ff7cf4631425d
treedeb85e2d04b9a7fea469c04c5047d50b544c1472
parent73a18745da1e0a6340e84233d57f4bb42ec66d37
LP#1145213: improvements to record merge

This patch checks for suffix and prefix of call number before merging
assets and ensures that unused call number records are marked
deleted.

To test:

[0] Apply the patch.
[1] Attempt a record merge where each record has a volumes with the
    same call number label and owning library but different
    affixes. Verify that the volumes and their associated copies
    are not merged onto the same volume..
[2] Attempt a merge with records having matching volumes. Verify
    that the copies are moved to one volume and that the other is
    marked deleted.

Signed-off-by: Rogan Hamby <rhamby@equinoxinitiative.org>
Signed-off-by: Cesar Velez <cesar.velez@equinoxinitiative.org>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/sql/Pg/999.functions.global.sql