[open-ils-commits] r14763 - in trunk/Open-ILS/src/perlmods/OpenILS/Application: . Cat (dbs)
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Nov 4 00:49:15 EST 2009
Author: dbs
Date: 2009-11-04 00:49:12 -0500 (Wed, 04 Nov 2009)
New Revision: 14763
Modified:
trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm
trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat/BibCommon.pm
Log:
Adjust the leader/05 of records that have been deleted or undeleted
Complies with http://www.loc.gov/marc/bibliographic/bdleader.html
Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat/BibCommon.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat/BibCommon.pm 2009-11-04 04:31:17 UTC (rev 14762)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat/BibCommon.pm 2009-11-04 05:49:12 UTC (rev 14763)
@@ -312,6 +312,12 @@
$rec->active('f');
$rec->editor( $editor->requestor->id );
$rec->edit_date('now');
+
+ # Set the leader/05 to indicate that the record has been deleted
+ my $marc = $rec->marc();
+ $marc =~ s{(<leader>.{5}).}{$1d};
+ $rec->marc($marc);
+
$editor->update_biblio_record_entry($rec) or return $editor->event;
return undef;
Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm 2009-11-04 04:31:17 UTC (rev 14762)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm 2009-11-04 05:49:12 UTC (rev 14763)
@@ -216,6 +216,11 @@
$record->deleted('f');
$record->active('t');
+ # Set the leader/05 to indicate that the record has been corrected/revised
+ my $marc = $record->marc();
+ $marc =~ s{(<leader>.{5}).}{$1c};
+ $record->marc($marc);
+
# no 2 non-deleted records can have the same tcn_value
my $existing = $e->search_biblio_record_entry(
{ deleted => 'f',
More information about the open-ils-commits
mailing list