Bugzilla – Attachment 19013 Details for
Bug 9673
Track when items are marked as lost or withdrawn
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 9673 - Track when items are marked as lost or withdrawn - QA Followup 3 - Clear 'on' fields when clearing statuses
Bug-9673---Track-when-items-are-marked-as-lost-or-.patch (text/plain), 1.27 KB, created by
Kyle M Hall (khall)
on 2013-06-14 14:00:37 UTC
(
hide
)
Description:
Bug 9673 - Track when items are marked as lost or withdrawn - QA Followup 3 - Clear 'on' fields when clearing statuses
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2013-06-14 14:00:37 UTC
Size:
1.27 KB
patch
obsolete
>From 2b9f4a84d52b1672f13258cb098a57c7c164b6e9 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 14 Jun 2013 09:59:55 -0400 >Subject: [PATCH] Bug 9673 - Track when items are marked as lost or withdrawn - QA Followup 3 - Clear 'on' fields when clearing statuses > >--- > C4/Items.pm | 9 +++++++++ > 1 files changed, 9 insertions(+), 0 deletions(-) > >diff --git a/C4/Items.pm b/C4/Items.pm >index a4eaa34..facdcbb 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -537,6 +537,7 @@ sub ModItem { > > $item->{onloan} = undef if $item->{itemlost}; > >+ # Only call GetItem if we need to set an "on" date field > if ( $item->{itemlost} || $item->{wthdrawn} ) { > my $pre_mod_item = GetItem( $item->{'itemnumber'} ); > for my $field (qw( itemlost wthdrawn )) { >@@ -553,6 +554,14 @@ sub ModItem { > } > } > } >+ # If the field is defined but empty, we are removing and, >+ # and thus need to clear out the 'on' field as well >+ if ( defined( $item->{itemlost} ) && !$item->{itemlost} ) { >+ $item->{itemlost_on} = undef; >+ } >+ if ( defined( $item->{wthdrawn} ) && !$item->{wthdrawn} ) { >+ $item->{wthdrawn_on} = undef; >+ } > > _set_derived_columns_for_mod($item); > _do_column_fixes_for_mod($item); >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 9673
:
15567
|
15890
|
16002
|
16003
|
16032
|
16033
|
16642
|
16643
|
16644
|
16645
|
16646
|
18031
|
18032
|
18033
|
18034
|
19013
|
19014
|
19079
|
19080
|
19120
|
19121
|
19483
|
19484
|
19485
|
19486
|
19487
|
19488
|
19489
|
19490
|
19492
|
21730
|
21731
|
22690
|
22691