From 9c0c3e7bcd56267bc2ff9df3129b5772f81cad21 Mon Sep 17 00:00:00 2001 From: erickson Date: Wed, 13 Jun 2007 18:07:03 +0000 Subject: [PATCH] merging tcn collision fix from rel_1_0 git-svn-id: svn://svn.open-ils.org/ILS/trunk@7428 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/Application/Cat.pm | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm b/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm index eb521ded3d..18fa7f0daf 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm @@ -214,15 +214,24 @@ sub biblio_record_replace_marc { # XXX should .update even bother with the tcn_info if it's not going to replace it? # there is the potential for returning a TCN_EXISTS event, even though no replacement happens - my( $tcn, $tsource, $marcdoc, $evt) = - _find_tcn_info($storage, $newxml, $override, $recid); + my( $tcn, $tsource, $marcdoc, $evt); - return $evt if $evt; + if($fixtcn or $override) { + + ($tcn, $tsource, $marcdoc, $evt) = + _find_tcn_info($storage, $newxml, $override, $recid); + + return $evt if $evt; - if( $fixtcn ) { $rec->tcn_value($tcn); $rec->tcn_source($tsource); - } + + } else { + + $marcdoc = __make_marc_doc($newxml); + } + + $rec->source(bib_source_from_name($source)) if $source; $rec->editor($e->requestor->id); -- 2.11.0