From ee6cb869235213dec6fe059a12d51c03f831fedf Mon Sep 17 00:00:00 2001 From: erickson Date: Wed, 9 Aug 2006 15:39:49 +0000 Subject: [PATCH] filled in some gaps WRT editor/edit_date on copies and volumes git-svn-id: svn://svn.open-ils.org/ILS/trunk@5405 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/Application/Cat.pm | 11 +++++++++++ Open-ILS/src/perlmods/OpenILS/Application/Cat/Merge.pm | 2 ++ Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm | 2 ++ 3 files changed, 15 insertions(+) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm b/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm index 0643e96bae..24c3d5c233 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Cat.pm @@ -917,6 +917,9 @@ sub fleshed_volume_update { my $copies = $vol->copies; $vol->clear_copies; + $vol->editor($editor->requestor->id); + $vol->edit_date('now'); + if( $vol->isdeleted ) { $logger->info("vol-update: deleting volume"); @@ -1018,6 +1021,8 @@ sub update_copy { my $orig_copy = $editor->retrieve_asset_copy($copy->id); my $orig_vol = $editor->retrieve_asset_call_number($copy->call_number); + $copy->editor($editor->requestor->id); + $copy->edit_date('now'); return $editor->event unless $editor->update_asset_copy( $copy, {checkperm=>1, permorg=>$vol->owning_lib}); @@ -1035,6 +1040,8 @@ sub remove_empty_objects { # delete this volume if it's not already marked as deleted unless( $U->is_true($vol->deleted) || $vol->isdeleted ) { $vol->deleted('t'); + $vol->editor($editor->requestor->id); + $vol->edit_date('now'); $editor->update_asset_call_number($vol, {checkperm=>0}) or return $editor->event; } @@ -1065,6 +1072,8 @@ sub delete_copy { $logger->info("vol-update: deleting copy ".$copy->id); $copy->deleted('t'); + $copy->editor($editor->requestor->id); + $copy->edit_date('now'); $editor->update_asset_copy( $copy, {checkperm=>1, permorg=>$vol->owning_lib}) or return $editor->event; @@ -1176,6 +1185,8 @@ sub create_volume { $vol->creator($editor->requestor->id); $vol->create_date('now'); + $vol->editor($editor->requestor->id); + $vol->edit_date('now'); $vol->clear_id; $editor->create_asset_call_number($vol) or return $editor->event; diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Cat/Merge.pm b/Open-ILS/src/perlmods/OpenILS/Application/Cat/Merge.pm index 4e29cec829..fec432cd92 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Cat/Merge.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Cat/Merge.pm @@ -86,6 +86,8 @@ sub merge_records { $logger->debug("merge: moving volume ". $vol->id." from record ".$vol->record. " to $master"); + $vol->editor( $editor->requestor->id ); + $vol->edit_date('now'); $vol->record( $master ); $editor->update_asset_call_number($vol) or return $editor->event; diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm index ece57b6ab8..d12b232426 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm @@ -783,6 +783,8 @@ sub update_copy { $copy->status($stat->id) if $stat; $copy->location($loc->id) if $loc; $copy->circ_lib($circ_lib->id) if $circ_lib; + $copy->editor($self->editor->requestor->id); + $copy->edit_date('now'); return $self->bail_on_events($self->editor->event) unless $self->editor->update_asset_copy($self->copy); -- 2.11.0